Domanda

I'm learning to use backbone so I started with the yeoman backbone scaffolding system.

It's similar to everything I know if rails so far... There's a terminal command:

$ yo backbone //creates your file tree in your app directory
$ rails new App //creates your file tree in a new directory

There's a command for making components of your MVC structure:

$ yo backbone:model user //generates the files for a user model
$ rails generate model user //generates the files for a user model

But when I go to destroy/undo/rollback/delete the MVC component I run into issues.

$ yo ?????
$ rails destroy model user //rolls back the addition

Thanks!

È stato utile?

Soluzione

No, we don't have a destroy like in rails. We recommend to use some version control, so that you can easily revert the last change. You can find a discussion on the same on generator repository. As a Team we think that incorporating destroy into yeoman core is complex to maintain.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top