Creating a new component

Setup

  1. Start with an empty folder.
    • Optional: Create a new project on GitHub, select project type "Node", clone & use that folder for automatic GitHub integration on init.
  2. Create a new npm project in that folder (npm init)
  3. npm install --save-dev react-sapling
  4. Run ./node_modules/.bin/sapling init

That's it! You now have a component project that's ready to hack on.

Available Commands after init

  • npm start: run a development server for your component project
  • npm test: run tests for your component
  • npm run build: build component & docs (to ./dist)
  • npm gh:publish: publish component docs to GitHub pages
  • npm run: list of other commands available

results matching ""

    No results matching ""