Skip to content
This repository has been archived by the owner on Jan 11, 2019. It is now read-only.

Add ability to be used as a Yeoman generator #105

Closed

Conversation

alexlafroscia
Copy link

Enables use of the project as a Yeoman generator. Tries to leave the project structure as close to the original as possible.

My suggestion, though, would be to release version 6.0.0 that is not backward compatible with the current structure, and go all in on Yeoman. You may not want to make that big of a change, but cloning a starter kit and changing it is kind of a weird pattern and the current setup doesn't really allow people to make changes to their configuration, which is something that Yeoman would allow you to configure on installation, which would be pretty sweet. If you were interested in that kind of more-drastic change, I would be happy to add to this PR to make that happen.

The major change, if you were to do that, would be moving the current root of the project under either app/ or generators/app (depends on your preferences). That's really all that has to change, although you could start to build up features that are provided by the user at installation time (like setting the name of the project in the package.json dynamically).

Changes

  • Tweaked the package.json file to provide the requirements for the Yeoman
  • Added a default "app" generator that copies over the required files to the new destination and runs the dependency installation

Testing the Generator

  • Install yeoman
  • Pull this PR locally and install the dependencies
  • Run npm link in the repo, which will add it to the list of generators available to yeoman
  • Run yo in the directory that you want to create a new project, and choose the option for React Isomorphic Starterkit

Closes #2

- Tweaked the `package.json` file to provide the requirements for the Yeoman
- Added a default "app" generator that copies over the required files to the new destination and runs the dependency installation
@RickWong
Copy link
Owner

RickWong commented Feb 4, 2016

Thanks. I will be reviewing the changes shortly.

@RickWong
Copy link
Owner

Sorry, I haven't had much time to do OSS work lately.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Create a Yeoman generator
2 participants