Skip to content

oncomouse/hyperapp-starter

Repository files navigation

@oncomouse/hyperapp-starter

Opinionated starter pack for building apps using hyperapp. hyperapp-effects is also provided for more Elm-style goodness.

For stylesheets, picostyle is provided. Additionally, node-sass and a variety of PostCSS plugins are installed. You can also use CSS modules or tachyons for styling components.

Testing is supported through the Mocha framework (with help from zinserjan/mocha-webpack). Chai (for assertions), Sinon (for spies, mocks, and stubs), and JSDom are all also provided. Check the .spec.js files in components/, containers/, and actions/ to see some examples to get started writing unit tests.

Getting Started

Run npm install or yarn install to install packages.

You may also want to reinitialize git, which can be done by running:

rm -rf .git
git init
git add .
git commit -m "Initial Commit"

Developing

There are a number of scripts already available for supporting development:

  • Start Development Servernpm run start
  • Build Production Codenpm run build
  • Visualize Bundle Sizenpm run analyze
  • Unit Testingnpm run mocha
    • npm run mocha:watch to live update unit tests
  • Checking Code Qualitynpm run lint
    • npm run lint -- --fix to fix errors automatically

Deploying

Run yarn build or npm run build to build an optimized, production version of your app. It will be in the build/ directory.

Debugging

npm run analyze

Also: env NODE_ENV=production webpack --json > stats.json and upload to Webpack Visualizer

Adding Routing

Click here for instructions

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors