Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/tonytonyjan/rails_on_webpack

This product is a demonstration of integration between Rails and Webpack without using any ruby gem.
https://github.com/tonytonyjan/rails_on_webpack

Last synced: about 1 month ago
JSON representation

This product is a demonstration of integration between Rails and Webpack without using any ruby gem.

Awesome Lists containing this project

README

        

# Rails on Webpack

This product is a demonstration of integration between Rails and Webpack without using any ruby gem, including some usefule tools and packages such as:

- SASS
- CoffeeScript
- Material Design Icons
- React
- ES6

If you really want to use a gem rather than DIY, [click here](http://github.com/tonytonyjan/webpack_stats)

## Usage

```
bundle
npm i -D
foreman start
```

## Production Build

You can set `WEBPACK_ENV` environment variable to `production` to build optimized assets. Briefly, scripts are compressed, and styles will be extracted into a file.

## How it works?

It's simple to intergrate Rails with webpack by using the its stats file and overwriting `#compute_asset_path`.