Skip to content

Commit

Permalink
Update webpacker
Browse files Browse the repository at this point in the history
  • Loading branch information
mrhead committed Apr 11, 2019
1 parent 5ee1ffc commit 02f4cb0
Show file tree
Hide file tree
Showing 6 changed files with 2,894 additions and 2,240 deletions.
29 changes: 17 additions & 12 deletions .babelrc
Original file line number Diff line number Diff line change
@@ -1,18 +1,23 @@
{
"presets": [
["env", {
"modules": false,
"targets": {
"browsers": "> 1%",
"uglify": true
},
"useBuiltIns": true
}]
[
"@babel/preset-env",
{
"modules": false,
"targets": {
"browsers": "> 1%",
}
}
]
],

"plugins": [
"syntax-dynamic-import",
"transform-object-rest-spread",
["transform-class-properties", { "spec": true }]
"@babel/plugin-syntax-dynamic-import",
"@babel/plugin-proposal-object-rest-spread",
[
"@babel/plugin-proposal-class-properties",
{
"spec": true
}
]
]
}
2 changes: 1 addition & 1 deletion Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ GEM
activemodel (>= 5.0)
bindex (>= 0.4.0)
railties (>= 5.0)
webpacker (3.5.5)
webpacker (4.0.2)
activesupport (>= 4.2)
rack-proxy (>= 0.6.1)
railties (>= 4.2)
Expand Down
6 changes: 5 additions & 1 deletion bin/webpack
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,8 @@ require "bundler/setup"

require "webpacker"
require "webpacker/webpack_runner"
Webpacker::WebpackRunner.run(ARGV)

APP_ROOT = File.expand_path("..", __dir__)
Dir.chdir(APP_ROOT) do
Webpacker::WebpackRunner.run(ARGV)
end
6 changes: 5 additions & 1 deletion bin/webpack-dev-server
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,8 @@ require "bundler/setup"

require "webpacker"
require "webpacker/dev_server_runner"
Webpacker::DevServerRunner.run(ARGV)

APP_ROOT = File.expand_path("..", __dir__)
Dir.chdir(APP_ROOT) do
Webpacker::DevServerRunner.run(ARGV)
end
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
"name": "stimulus-search",
"private": true,
"dependencies": {
"@rails/webpacker": "3.5",
"@rails/webpacker": "4.0.2",
"stimulus": "^1.1.0"
},
"devDependencies": {
"webpack-dev-server": "2.11.2"
"webpack-dev-server": "3.3.1"
}
}
Loading

0 comments on commit 02f4cb0

Please sign in to comment.