Jolteon – Babel/Electron/React/Browserify/Sass application stack

zzhhhuc 8年前發布 | 13K 次閱讀 React Electron JavaScript開發 JavaScript

來自: https://github.com/vulpino/jolteon

Jolteon

Babel + Electron + React + Browserify + Sass application stack. Gets the stupid work done so you can actually make something.

What stupid work, exactly?

  • Build your app with one command.
  • Open a live-reloading instance of your app with another command.
  • Lint your app using a third command.

How to get started

  • npm install -g gulp-cli electron-prebuilt
  • git clone https://github.com/vulpino/jolteon
  • cd jolteon
  • npm install

If you're on windows...

gulp package-osx will fail because symlinks. Sorry. Blame gulp-atom-electron.

Directory Structure

  • Your client HTML lives in app/.
  • Your client javascript lives in app/js/.
  • Your client SCSS lives in app/scss.
  • Your react components live in app/js/components/.
  • Your electron server code lives in src/.
  • Everything is programmed using Javascript, the new, cool kind (ES2015).

Building

  • Build the client and server bundles: gulp build
  • Watch app/ and src/ for changes and update build/ automagically: gulp watch
  • Lint everything (We use StandardJS, but you can modify the .eslintrc): gulp lint
  • Open up the app: gulp serve . This will also live reload everything, so don't worry about that.
  • Package the app for release: gulp package .

 本文由用戶 zzhhhuc 自行上傳分享,僅供網友學習交流。所有權歸原作者,若您的權利被侵害,請聯系管理員。
 轉載本站原創文章,請注明出處,并保留原始鏈接、圖片水印。
 本站是一個以用戶分享為主的開源技術平臺,歡迎各類分享!