Skip to content
No description, website, or topics provided.
Haskell JavaScript Nix Shell
Branch: master
Clone or download
Latest commit 721d122 Aug 8, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
app Run ormolu on all files Aug 7, 2019
nix Add ormolu to nix and make an hindent imposter with it Aug 6, 2019
package/npm Bump version to 3.0.0-rc1 Aug 6, 2019
resources hot-reloading Dec 20, 2018
script Make formatting script work with ormolu Aug 7, 2019
src Run ormolu on all files Aug 7, 2019
test Run ormolu on all files Aug 7, 2019
.envrc Use nix and direnv Aug 6, 2019
.gitattributes make lfs tracking more generic Mar 30, 2017
.gitignore Use nix and direnv Aug 6, 2019
.hindent.yaml make require safer Mar 1, 2017
.travis.yml fixup! Check format in travis Aug 7, 2019
LICENSE update license Jan 2, 2019
PUBLISHING.md update readme because before publishing, npm install should fail Apr 9, 2018
README.md Make formatting script work with ormolu Aug 7, 2019
Setup.hs Cleaning day (#26) Dec 7, 2017
package.yaml Bump version to 3.0.0-rc1 Aug 6, 2019
shell.nix
stack.yaml Use nix and direnv Aug 6, 2019

README.md

jetpack Build Status

NOTE: Jetpack is an internal NoRedInk build tool that we decided to open source in hopes that it might be useful to others. It has never been our goal to develop a fully featured front-end build system for other use cases; it currently compiles only Elm and CoffeeScript because that's all our build needs. We're open to potentially accepting outside contributions to support other use cases, but please understand that this remains an internal tool first, and we can't make any promises that anything will be accepted. Thanks for understanding, and by all means don't feel bad about forking! ❤️

Motivation

Webpack didn't work out for us; it did more than we needed, and builds were taking too long. Jetpack is focused on compilation speed. It only compiles the stuff we need and creates the concatenated output js.

Given an entry point, it follows all require statements and creates a dependency tree. It then builds all files using the appropriate compiler, concatenates the compiled js, and wraps modules in functions so that the requires know how to get the right functions.

Configuration

{
  "entry_points": "./FOLDER/TO/THE/ENTRY_POINTS",
  "modules_directories": [ // folders where jetpack should try to find modules
    "./node_modules",
    "./vendor/assets/javascripts/FOO"
  ],
  "source_directory": "./ui/src", // jetpack will try to resolve modules in source_directory before checking in modules_directories
  "elm_root_directory": "./ui", // where your elm-package.json is
  "temp_directory": "./.jetpack/build_artifacts", // jetpack's build_artifacts will be here
  "log_directory": "./.jetpack/logs", // jetpack will log stuff in here
  "output_js_directory": "assets/javascripts", // js will be written to this folder
  "elm_bin_path": "./node_modules/.bin/elm-make", // path to elm binary
  "coffee_path": "./node_modules/.bin/coffee", // path to coffee
  "no_parse": ["./node_modules/clipboard/dist/clipboard.js"] // files that shouldn't be parsed
}

Development

direnv allow
stack setup
stack build
stack test

Run ./script/format.sh to format everything correctly.

You can’t perform that action at this time.