# Use Turbo without Turbo Drive

**URL:** https://discuss.hotwired.dev/t/use-turbo-without-turbo-drive/2310
**Category:** General
**Created:** [February 15, 2021, 3:56pm UTC](https://discuss.hotwired.dev/t/use-turbo-without-turbo-drive/2310 "2021-02-15T15:56:33Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![renestalder](https://yyz1.discourse-cdn.com/flex027/user_avatar/discuss.hotwired.dev/renestalder/32/1360_2.png) [@renestalder](https://discuss.hotwired.dev/u/renestalder)
#### Post date: [February 15, 2021, 3:56pm UTC](https://discuss.hotwired.dev/t/use-turbo-without-turbo-drive/2310/1 "2021-02-15T15:56:33Z")

</div>

In a non-ruby environment, the Turbo documentation suggests a complete import of Turbo. After the import, the whole Turbo framework is active on the page.

I didn’t really realize that first as I only wanted to use turboframes. It activated Turbo Drive on the whole website, which I didn’t want to use. So, I wonder, is there no other way to initialize individual features of the Turbo framework part? Like only activate or import the turboframes part?

---

<div class="post-metadata">

### Author: ![renestalder](https://yyz1.discourse-cdn.com/flex027/user_avatar/discuss.hotwired.dev/renestalder/32/1360_2.png) [@renestalder](https://discuss.hotwired.dev/u/renestalder)
#### Post date: [August 25, 2021, 7:55pm UTC](https://discuss.hotwired.dev/t/use-turbo-without-turbo-drive/2310/2 "2021-08-25T19:55:14Z")

</div>

There’s now a way to deactivate Turbo Drive by default since rc.2 of Turbo.

> <https://github.com/hotwired/turbo/pull/196>
>
> I have a project where customers have existing layouts and I don't want them to …have to disable Turbo Drive using \`data-turbo="false"\` in their layouts, but I still want them to be able to use Turbo in an opt-in fashion. Right now I monkey patch it like this, which seems hacky:
> 
> \`\`\`js
> import { Turbo } from "@hotwired/turbo-rails";
> Turbo.navigator.delegate.elementIsNavigable = function(element) {
> const container = element === null || element === void 0 ? void 0 : element.closest("\[data-turbo\]");
> if (container) {
> return container.getAttribute("data-turbo") == "true";
> } else {
> return false;
> }
> }
> \`\`\`
> 
> Turbo Drive seems to be the only part of Turbo which is not opt-in, so it seems wrong to not be able to configure it to behave that way. This PR would allow developers to disable Turbo Drive by default, and then opt-in by adding \`data-turbo="true"\` wherever they want to use Turbo Drive (including in the \`\<html\>\` or \`\<body\>\` tags). Usage after it's in \`turbo-rails\`:
> 
> \`\`\`js
> import { Turbo } from "@hotwired/turbo-rails";
> Turbo.disableDriveByDefault();
> \`\`\`
> 
> The name might seem a little verbose, but I thought it was good because it communicates that it's not entirely disabled, and still usable in an opt-in fashion.
> 
> Fixes #190
> Related to #136
> 
> Fixes hotwired/turbo-rails#139
