version update
This commit is contained in:
parent
e966a778c0
commit
123c943637
18
.babelrc
18
.babelrc
@ -1,18 +0,0 @@
|
||||
{
|
||||
"presets": [
|
||||
["env", {
|
||||
"modules": false,
|
||||
"targets": {
|
||||
"browsers": "> 1%",
|
||||
"uglify": true
|
||||
},
|
||||
"useBuiltIns": true
|
||||
}]
|
||||
],
|
||||
|
||||
"plugins": [
|
||||
"syntax-dynamic-import",
|
||||
"transform-object-rest-spread",
|
||||
["transform-class-properties", { "spec": true }]
|
||||
]
|
||||
}
|
1
.browserslistrc
Normal file
1
.browserslistrc
Normal file
@ -0,0 +1 @@
|
||||
> 1%, not ie <= 12
|
@ -1,7 +0,0 @@
|
||||
plugins:
|
||||
postcss-import: {}
|
||||
postcss-cssnext: {
|
||||
features: {
|
||||
customProperties: false
|
||||
}
|
||||
}
|
@ -1 +1 @@
|
||||
2.4.4
|
||||
2.6.2
|
||||
|
12
Dockerfile
12
Dockerfile
@ -1,17 +1,15 @@
|
||||
FROM phusion/passenger-ruby24:latest
|
||||
FROM phusion/passenger-ruby26:1.0.5
|
||||
|
||||
# Use baseimage-docker's init process.
|
||||
CMD ["/sbin/my_init"]
|
||||
|
||||
# Install Node
|
||||
RUN curl -sL https://deb.nodesource.com/setup_8.x | bash - && \
|
||||
curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - && \
|
||||
RUN curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | apt-key add - && \
|
||||
echo "deb https://dl.yarnpkg.com/debian/ stable main" > /etc/apt/sources.list.d/yarn.list && \
|
||||
apt-get update && \
|
||||
apt-get install -y --no-install-recommends nodejs yarn && \
|
||||
apt-get install -y --no-install-recommends yarn && \
|
||||
apt-get clean && rm -rf /var/lib/apt/lists/*
|
||||
|
||||
RUN ls
|
||||
RUN gem update --system && gem install bundler
|
||||
|
||||
# Enable Nginx / Passenger
|
||||
@ -37,10 +35,10 @@ RUN chown -R app:app /home/app/parsley/
|
||||
WORKDIR /home/app/parsley/
|
||||
|
||||
COPY Gemfile* ./
|
||||
RUN bundle install --deployment --jobs 4 --without development test
|
||||
RUN su app -c "bundle install --deployment --jobs 4 --without development test"
|
||||
|
||||
COPY package.json yarn.lock ./
|
||||
RUN yarn install --production=true
|
||||
RUN su app -c "yarn install --production=true"
|
||||
|
||||
# Copy the app into the image
|
||||
COPY --chown="app" . .
|
||||
|
13
Gemfile
13
Gemfile
@ -1,22 +1,21 @@
|
||||
source 'https://rubygems.org'
|
||||
|
||||
gem 'rails', '5.2.2'
|
||||
gem 'rails', '5.2.2.1'
|
||||
gem 'pg', '~> 1.1.4'
|
||||
|
||||
gem 'webpacker', '3.5.5'
|
||||
gem 'webpacker', '4.0.2'
|
||||
gem 'bootsnap', '>= 1.1.0', require: false
|
||||
|
||||
gem 'jbuilder', '~> 2.8'
|
||||
#gem 'jbuilder', git: 'https://github.com/rails/jbuilder', branch: 'master'
|
||||
|
||||
gem 'oj', '~> 3.7.8'
|
||||
gem 'oj', '~> 3.7.11'
|
||||
|
||||
gem 'kaminari', '~> 1.1.1'
|
||||
gem 'unitwise', '~> 2.2.0'
|
||||
gem 'redcarpet', '~> 3.4.0'
|
||||
|
||||
gem 'dalli', '~> 2.7.9'
|
||||
gem 'airbrake', '~> 8.0.1'
|
||||
gem 'dalli', '~> 2.7.10'
|
||||
|
||||
# Use ActiveModel has_secure_password
|
||||
gem 'bcrypt', '~> 3.1.12'
|
||||
@ -26,9 +25,9 @@ gem 'tzinfo-data'
|
||||
group :development, :test do
|
||||
|
||||
gem 'puma', '~> 3.12'
|
||||
gem 'sqlite3'
|
||||
gem 'sqlite3', '~> 1.3.13'
|
||||
|
||||
gem 'guard', '~> 2.14.2'
|
||||
gem 'guard', '~> 2.15.0'
|
||||
gem 'guard-rspec', require: false
|
||||
gem 'rspec-rails', '~> 3.8.0'
|
||||
gem 'rails-controller-testing'
|
||||
|
110
Gemfile.lock
110
Gemfile.lock
@ -1,60 +1,56 @@
|
||||
GEM
|
||||
remote: https://rubygems.org/
|
||||
specs:
|
||||
actioncable (5.2.2)
|
||||
actionpack (= 5.2.2)
|
||||
actioncable (5.2.2.1)
|
||||
actionpack (= 5.2.2.1)
|
||||
nio4r (~> 2.0)
|
||||
websocket-driver (>= 0.6.1)
|
||||
actionmailer (5.2.2)
|
||||
actionpack (= 5.2.2)
|
||||
actionview (= 5.2.2)
|
||||
activejob (= 5.2.2)
|
||||
actionmailer (5.2.2.1)
|
||||
actionpack (= 5.2.2.1)
|
||||
actionview (= 5.2.2.1)
|
||||
activejob (= 5.2.2.1)
|
||||
mail (~> 2.5, >= 2.5.4)
|
||||
rails-dom-testing (~> 2.0)
|
||||
actionpack (5.2.2)
|
||||
actionview (= 5.2.2)
|
||||
activesupport (= 5.2.2)
|
||||
actionpack (5.2.2.1)
|
||||
actionview (= 5.2.2.1)
|
||||
activesupport (= 5.2.2.1)
|
||||
rack (~> 2.0)
|
||||
rack-test (>= 0.6.3)
|
||||
rails-dom-testing (~> 2.0)
|
||||
rails-html-sanitizer (~> 1.0, >= 1.0.2)
|
||||
actionview (5.2.2)
|
||||
activesupport (= 5.2.2)
|
||||
actionview (5.2.2.1)
|
||||
activesupport (= 5.2.2.1)
|
||||
builder (~> 3.1)
|
||||
erubi (~> 1.4)
|
||||
rails-dom-testing (~> 2.0)
|
||||
rails-html-sanitizer (~> 1.0, >= 1.0.3)
|
||||
activejob (5.2.2)
|
||||
activesupport (= 5.2.2)
|
||||
activejob (5.2.2.1)
|
||||
activesupport (= 5.2.2.1)
|
||||
globalid (>= 0.3.6)
|
||||
activemodel (5.2.2)
|
||||
activesupport (= 5.2.2)
|
||||
activerecord (5.2.2)
|
||||
activemodel (= 5.2.2)
|
||||
activesupport (= 5.2.2)
|
||||
activemodel (5.2.2.1)
|
||||
activesupport (= 5.2.2.1)
|
||||
activerecord (5.2.2.1)
|
||||
activemodel (= 5.2.2.1)
|
||||
activesupport (= 5.2.2.1)
|
||||
arel (>= 9.0)
|
||||
activestorage (5.2.2)
|
||||
actionpack (= 5.2.2)
|
||||
activerecord (= 5.2.2)
|
||||
activestorage (5.2.2.1)
|
||||
actionpack (= 5.2.2.1)
|
||||
activerecord (= 5.2.2.1)
|
||||
marcel (~> 0.3.1)
|
||||
activesupport (5.2.2)
|
||||
activesupport (5.2.2.1)
|
||||
concurrent-ruby (~> 1.0, >= 1.0.2)
|
||||
i18n (>= 0.7, < 2)
|
||||
minitest (~> 5.1)
|
||||
tzinfo (~> 1.1)
|
||||
airbrake (8.0.1)
|
||||
airbrake-ruby (~> 3.0)
|
||||
airbrake-ruby (3.1.0)
|
||||
tdigest (= 0.1.1)
|
||||
arel (9.0.0)
|
||||
bcrypt (3.1.12)
|
||||
bootsnap (1.3.2)
|
||||
bootsnap (1.4.1)
|
||||
msgpack (~> 1.0)
|
||||
builder (3.2.3)
|
||||
coderay (1.1.2)
|
||||
concurrent-ruby (1.1.4)
|
||||
concurrent-ruby (1.1.5)
|
||||
crass (1.0.4)
|
||||
dalli (2.7.9)
|
||||
dalli (2.7.10)
|
||||
database_cleaner (1.7.0)
|
||||
diff-lcs (1.3)
|
||||
erubi (1.8.0)
|
||||
@ -67,7 +63,7 @@ GEM
|
||||
formatador (0.2.5)
|
||||
globalid (0.4.2)
|
||||
activesupport (>= 4.2.0)
|
||||
guard (2.14.2)
|
||||
guard (2.15.0)
|
||||
formatador (>= 0.2.4)
|
||||
listen (>= 2.7, < 4.0)
|
||||
lumberjack (>= 1.0.12, < 2.0)
|
||||
@ -81,7 +77,7 @@ GEM
|
||||
guard (~> 2.1)
|
||||
guard-compat (~> 1.1)
|
||||
rspec (>= 2.99.0, < 4.0)
|
||||
i18n (1.5.3)
|
||||
i18n (1.6.0)
|
||||
concurrent-ruby (~> 1.0)
|
||||
jbuilder (2.8.0)
|
||||
activesupport (>= 4.2.0)
|
||||
@ -118,7 +114,7 @@ GEM
|
||||
mini_mime (1.0.1)
|
||||
mini_portile2 (2.4.0)
|
||||
minitest (5.11.3)
|
||||
msgpack (1.2.6)
|
||||
msgpack (1.2.9)
|
||||
multi_json (1.13.1)
|
||||
nenv (0.3.0)
|
||||
nio4r (2.3.1)
|
||||
@ -127,30 +123,30 @@ GEM
|
||||
notiffany (0.1.1)
|
||||
nenv (~> 0.1)
|
||||
shellany (~> 0.0)
|
||||
oj (3.7.8)
|
||||
oj (3.7.11)
|
||||
parslet (1.8.2)
|
||||
pg (1.1.4)
|
||||
pry (0.12.2)
|
||||
coderay (~> 1.1.0)
|
||||
method_source (~> 0.9.0)
|
||||
puma (3.12.0)
|
||||
puma (3.12.1)
|
||||
rack (2.0.6)
|
||||
rack-proxy (0.6.5)
|
||||
rack
|
||||
rack-test (1.1.0)
|
||||
rack (>= 1.0, < 3)
|
||||
rails (5.2.2)
|
||||
actioncable (= 5.2.2)
|
||||
actionmailer (= 5.2.2)
|
||||
actionpack (= 5.2.2)
|
||||
actionview (= 5.2.2)
|
||||
activejob (= 5.2.2)
|
||||
activemodel (= 5.2.2)
|
||||
activerecord (= 5.2.2)
|
||||
activestorage (= 5.2.2)
|
||||
activesupport (= 5.2.2)
|
||||
rails (5.2.2.1)
|
||||
actioncable (= 5.2.2.1)
|
||||
actionmailer (= 5.2.2.1)
|
||||
actionpack (= 5.2.2.1)
|
||||
actionview (= 5.2.2.1)
|
||||
activejob (= 5.2.2.1)
|
||||
activemodel (= 5.2.2.1)
|
||||
activerecord (= 5.2.2.1)
|
||||
activestorage (= 5.2.2.1)
|
||||
activesupport (= 5.2.2.1)
|
||||
bundler (>= 1.3.0)
|
||||
railties (= 5.2.2)
|
||||
railties (= 5.2.2.1)
|
||||
sprockets-rails (>= 2.0.0)
|
||||
rails-controller-testing (1.0.4)
|
||||
actionpack (>= 5.0.1.x)
|
||||
@ -161,9 +157,9 @@ GEM
|
||||
nokogiri (>= 1.6)
|
||||
rails-html-sanitizer (1.0.4)
|
||||
loofah (~> 2.2, >= 2.2.2)
|
||||
railties (5.2.2)
|
||||
actionpack (= 5.2.2)
|
||||
activesupport (= 5.2.2)
|
||||
railties (5.2.2.1)
|
||||
actionpack (= 5.2.2.1)
|
||||
activesupport (= 5.2.2.1)
|
||||
method_source
|
||||
rake (>= 0.8.7)
|
||||
thor (>= 0.19.0, < 2.0)
|
||||
@ -171,7 +167,6 @@ GEM
|
||||
rb-fsevent (0.10.3)
|
||||
rb-inotify (0.10.0)
|
||||
ffi (~> 1.0)
|
||||
rbtree (0.4.2)
|
||||
redcarpet (3.4.0)
|
||||
rspec (3.8.0)
|
||||
rspec-core (~> 3.8.0)
|
||||
@ -205,8 +200,6 @@ GEM
|
||||
activesupport (>= 4.0)
|
||||
sprockets (>= 3.0.0)
|
||||
sqlite3 (1.3.13)
|
||||
tdigest (0.1.1)
|
||||
rbtree (~> 0.4.2)
|
||||
thor (0.20.3)
|
||||
thread_safe (0.3.6)
|
||||
tzinfo (1.2.5)
|
||||
@ -218,7 +211,7 @@ GEM
|
||||
memoizable (~> 0.4)
|
||||
parslet (~> 1.5)
|
||||
signed_multiset (~> 0.2)
|
||||
webpacker (3.5.5)
|
||||
webpacker (4.0.2)
|
||||
activesupport (>= 4.2)
|
||||
rack-proxy (>= 0.6.1)
|
||||
railties (>= 4.2)
|
||||
@ -230,27 +223,26 @@ PLATFORMS
|
||||
ruby
|
||||
|
||||
DEPENDENCIES
|
||||
airbrake (~> 8.0.1)
|
||||
bcrypt (~> 3.1.12)
|
||||
bootsnap (>= 1.1.0)
|
||||
dalli (~> 2.7.9)
|
||||
dalli (~> 2.7.10)
|
||||
database_cleaner (~> 1.7.0)
|
||||
factory_bot_rails (~> 4.11.1)
|
||||
guard (~> 2.14.2)
|
||||
guard (~> 2.15.0)
|
||||
guard-rspec
|
||||
jbuilder (~> 2.8)
|
||||
kaminari (~> 1.1.1)
|
||||
oj (~> 3.7.8)
|
||||
oj (~> 3.7.11)
|
||||
pg (~> 1.1.4)
|
||||
puma (~> 3.12)
|
||||
rails (= 5.2.2)
|
||||
rails (= 5.2.2.1)
|
||||
rails-controller-testing
|
||||
redcarpet (~> 3.4.0)
|
||||
rspec-rails (~> 3.8.0)
|
||||
sqlite3
|
||||
sqlite3 (~> 1.3.13)
|
||||
tzinfo-data
|
||||
unitwise (~> 2.2.0)
|
||||
webpacker (= 3.5.5)
|
||||
webpacker (= 4.0.2)
|
||||
|
||||
BUNDLED WITH
|
||||
2.0.1
|
||||
|
@ -2,7 +2,7 @@
|
||||
<%
|
||||
manifest_data = Webpacker::manifest.refresh
|
||||
manifest_timestamp = File.mtime(Webpacker::config.public_manifest_path).to_i
|
||||
pack_assets = manifest_data.values.select { |asset| asset !~ /\.map$/ }
|
||||
pack_assets = manifest_data.select { |name, asset| name !~ /\.map$/ && name != 'entrypoints' }.values
|
||||
%>
|
||||
|
||||
var cacheName = "parsley-cache-<%= manifest_timestamp %>";
|
||||
|
70
babel.config.js
Normal file
70
babel.config.js
Normal file
@ -0,0 +1,70 @@
|
||||
module.exports = function(api) {
|
||||
var validEnv = ['development', 'test', 'production']
|
||||
var currentEnv = api.env()
|
||||
var isDevelopmentEnv = api.env('development')
|
||||
var isProductionEnv = api.env('production')
|
||||
var isTestEnv = api.env('test')
|
||||
|
||||
if (!validEnv.includes(currentEnv)) {
|
||||
throw new Error(
|
||||
'Please specify a valid `NODE_ENV` or ' +
|
||||
'`BABEL_ENV` environment variables. Valid values are "development", ' +
|
||||
'"test", and "production". Instead, received: ' +
|
||||
JSON.stringify(currentEnv) +
|
||||
'.'
|
||||
)
|
||||
}
|
||||
|
||||
return {
|
||||
presets: [
|
||||
isTestEnv && [
|
||||
require('@babel/preset-env').default,
|
||||
{
|
||||
targets: {
|
||||
node: 'current'
|
||||
}
|
||||
}
|
||||
],
|
||||
(isProductionEnv || isDevelopmentEnv) && [
|
||||
require('@babel/preset-env').default,
|
||||
{
|
||||
forceAllTransforms: true,
|
||||
useBuiltIns: 'entry',
|
||||
modules: false,
|
||||
exclude: ['transform-typeof-symbol']
|
||||
}
|
||||
]
|
||||
].filter(Boolean),
|
||||
plugins: [
|
||||
require('babel-plugin-macros'),
|
||||
require('@babel/plugin-syntax-dynamic-import').default,
|
||||
isTestEnv && require('babel-plugin-dynamic-import-node'),
|
||||
require('@babel/plugin-transform-destructuring').default,
|
||||
[
|
||||
require('@babel/plugin-proposal-class-properties').default,
|
||||
{
|
||||
loose: true
|
||||
}
|
||||
],
|
||||
[
|
||||
require('@babel/plugin-proposal-object-rest-spread').default,
|
||||
{
|
||||
useBuiltIns: true
|
||||
}
|
||||
],
|
||||
[
|
||||
require('@babel/plugin-transform-runtime').default,
|
||||
{
|
||||
helpers: false,
|
||||
regenerator: true
|
||||
}
|
||||
],
|
||||
[
|
||||
require('@babel/plugin-transform-regenerator').default,
|
||||
{
|
||||
async: false
|
||||
}
|
||||
]
|
||||
].filter(Boolean)
|
||||
}
|
||||
}
|
@ -1,7 +1,7 @@
|
||||
#!/usr/bin/env ruby
|
||||
|
||||
ENV["RAILS_ENV"] ||= ENV["RACK_ENV"] || "development"
|
||||
ENV["NODE_ENV"] ||= ENV["RAILS_ENV"]
|
||||
ENV["NODE_ENV"] ||= "development"
|
||||
|
||||
require "pathname"
|
||||
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
|
||||
@ -12,4 +12,8 @@ require "bundler/setup"
|
||||
|
||||
require "webpacker"
|
||||
require "webpacker/webpack_runner"
|
||||
|
||||
APP_ROOT = File.expand_path("..", __dir__)
|
||||
Dir.chdir(APP_ROOT) do
|
||||
Webpacker::WebpackRunner.run(ARGV)
|
||||
end
|
||||
|
@ -1,7 +1,7 @@
|
||||
#!/usr/bin/env ruby
|
||||
|
||||
ENV["RAILS_ENV"] ||= ENV["RACK_ENV"] || "development"
|
||||
ENV["NODE_ENV"] ||= ENV["RAILS_ENV"]
|
||||
ENV["NODE_ENV"] ||= "development"
|
||||
|
||||
require "pathname"
|
||||
ENV["BUNDLE_GEMFILE"] ||= File.expand_path("../../Gemfile",
|
||||
@ -12,4 +12,8 @@ require "bundler/setup"
|
||||
|
||||
require "webpacker"
|
||||
require "webpacker/dev_server_runner"
|
||||
|
||||
APP_ROOT = File.expand_path("..", __dir__)
|
||||
Dir.chdir(APP_ROOT) do
|
||||
Webpacker::DevServerRunner.run(ARGV)
|
||||
end
|
||||
|
@ -1,59 +0,0 @@
|
||||
|
||||
Airbrake.configure do |c|
|
||||
c.host = 'https://errbit.elbert.us'
|
||||
c.project_id = 13
|
||||
c.project_key = 'd2344e1439d68f942ee8fa09f18e69c6'
|
||||
|
||||
# Configures the root directory of your project. Expects a String or a
|
||||
# Pathname, which represents the path to your project. Providing this option
|
||||
# helps us to filter out repetitive data from backtrace frames and link to
|
||||
# GitHub files from our dashboard.
|
||||
# https://github.com/airbrake/airbrake-ruby#root_directory
|
||||
c.root_directory = Rails.root
|
||||
|
||||
# By default, Airbrake Ruby outputs to STDOUT. In Rails apps it makes sense to
|
||||
# use the Rails' logger.
|
||||
# https://github.com/airbrake/airbrake-ruby#logger
|
||||
c.logger = Rails.logger
|
||||
|
||||
# Configures the environment the application is running in. Helps the Airbrake
|
||||
# dashboard to distinguish between exceptions occurring in different
|
||||
# environments.
|
||||
# NOTE: This option must be set in order to make the 'ignore_environments'
|
||||
# option work.
|
||||
# https://github.com/airbrake/airbrake-ruby#environment
|
||||
c.environment = Rails.env
|
||||
|
||||
# Setting this option allows Airbrake to filter exceptions occurring in
|
||||
# unwanted environments such as :test.
|
||||
# NOTE: This option *does not* work if you don't set the 'environment' option.
|
||||
# https://github.com/airbrake/airbrake-ruby#ignore_environments
|
||||
c.ignore_environments = %w[test]
|
||||
|
||||
# A list of parameters that should be filtered out of what is sent to
|
||||
# Airbrake. By default, all "password" attributes will have their contents
|
||||
# replaced.
|
||||
# https://github.com/airbrake/airbrake-ruby#blacklist_keys
|
||||
c.blacklist_keys = [/password/i, /authorization/i]
|
||||
|
||||
# Alternatively, you can integrate with Rails' filter_parameters.
|
||||
# Read more: https://goo.gl/gqQ1xS
|
||||
# c.blacklist_keys = Rails.application.config.filter_parameters
|
||||
end
|
||||
|
||||
# A filter that collects request body information. Enable it if you are sure you
|
||||
# don't send sensitive information to Airbrake in your body (such as passwords).
|
||||
# https://github.com/airbrake/airbrake#requestbodyfilter
|
||||
# Airbrake.add_filter(Airbrake::Rack::RequestBodyFilter.new)
|
||||
|
||||
# Attaches thread & fiber local variables along with general thread information.
|
||||
# Airbrake.add_filter(Airbrake::Filters::ThreadFilter.new)
|
||||
|
||||
# Attaches loaded dependencies to the notice object
|
||||
# (under context/versions/dependencies).
|
||||
# Airbrake.add_filter(Airbrake::Filters::DependencyFilter.new)
|
||||
|
||||
# If you want to convert your log messages to Airbrake errors, we offer an
|
||||
# integration with the Logger class from stdlib.
|
||||
# https://github.com/airbrake/airbrake#logger
|
||||
# Rails.logger = Airbrake::AirbrakeLogger.new(Rails.logger)
|
@ -1,3 +1,5 @@
|
||||
process.env.NODE_ENV = process.env.NODE_ENV || 'development'
|
||||
|
||||
const environment = require('./environment')
|
||||
|
||||
module.exports = environment.toWebpackConfig()
|
||||
|
5
config/webpack/docker.js
Normal file
5
config/webpack/docker.js
Normal file
@ -0,0 +1,5 @@
|
||||
process.env.NODE_ENV = process.env.NODE_ENV || 'production'
|
||||
|
||||
const environment = require('./environment')
|
||||
|
||||
module.exports = environment.toWebpackConfig()
|
@ -1,8 +1,10 @@
|
||||
const { environment } = require('@rails/webpacker');
|
||||
const { VueLoaderPlugin } = require('vue-loader');
|
||||
const vue = require('./loaders/vue');
|
||||
const svg = require('./loaders/svg');
|
||||
|
||||
environment.loaders.append('vue', vue);
|
||||
environment.plugins.prepend('VueLoaderPlugin', new VueLoaderPlugin());
|
||||
environment.loaders.prepend('vue', vue);
|
||||
environment.loaders.prepend('svg', svg);
|
||||
|
||||
const fileLoader = environment.loaders.get('file');
|
||||
|
@ -1,13 +1,6 @@
|
||||
const { dev_server: devServer } = require('@rails/webpacker').config
|
||||
|
||||
const isProduction = process.env.NODE_ENV === 'production'
|
||||
const inDevServer = process.argv.find(v => v.includes('webpack-dev-server'))
|
||||
const extractCSS = !(inDevServer && (devServer && devServer.hmr)) || isProduction
|
||||
|
||||
module.exports = {
|
||||
test: /\.vue(\.erb)?$/,
|
||||
use: [{
|
||||
loader: 'vue-loader',
|
||||
options: { extractCSS }
|
||||
loader: 'vue-loader'
|
||||
}]
|
||||
}
|
||||
|
@ -1,3 +1,5 @@
|
||||
process.env.NODE_ENV = process.env.NODE_ENV || 'production'
|
||||
|
||||
const environment = require('./environment')
|
||||
|
||||
module.exports = environment.toWebpackConfig()
|
||||
|
@ -1,3 +1,5 @@
|
||||
process.env.NODE_ENV = process.env.NODE_ENV || 'development'
|
||||
|
||||
const environment = require('./environment')
|
||||
|
||||
module.exports = environment.toWebpackConfig()
|
||||
|
@ -1,10 +1,13 @@
|
||||
# Note: You must restart bin/webpack-dev-server for changes to take effect
|
||||
|
||||
default: &default
|
||||
public_root_path: public
|
||||
source_path: app/javascript
|
||||
source_entry_path: packs
|
||||
public_output_path: packs
|
||||
cache_path: tmp/cache/webpacker
|
||||
check_yarn_integrity: false
|
||||
webpack_compile_output: false
|
||||
|
||||
# Additional paths webpack should lookup modules
|
||||
# ['app/assets', 'engine/foo/app/assets']
|
||||
@ -13,8 +16,26 @@ default: &default
|
||||
# Reload manifest.json on all requests so we reload latest compiled packs
|
||||
cache_manifest: false
|
||||
|
||||
# Extract and emit a css file
|
||||
extract_css: false
|
||||
|
||||
static_assets_extensions:
|
||||
- .jpg
|
||||
- .jpeg
|
||||
- .png
|
||||
- .gif
|
||||
- .tiff
|
||||
- .ico
|
||||
- .svg
|
||||
- .eot
|
||||
- .otf
|
||||
- .ttf
|
||||
- .woff
|
||||
- .woff2
|
||||
|
||||
extensions:
|
||||
- .vue
|
||||
- .mjs
|
||||
- .js
|
||||
- .sass
|
||||
- .scss
|
||||
@ -32,6 +53,9 @@ development:
|
||||
<<: *default
|
||||
compile: true
|
||||
|
||||
# Verifies that versions and hashed value of the package contents in the project's package.json
|
||||
check_yarn_integrity: true
|
||||
|
||||
# Reference: https://webpack.js.org/configuration/dev-server/
|
||||
dev_server:
|
||||
https: false
|
||||
@ -59,11 +83,18 @@ test:
|
||||
# Compile test packs to a separate directory
|
||||
public_output_path: packs-test
|
||||
|
||||
production:
|
||||
production: &production
|
||||
<<: *default
|
||||
|
||||
# Production depends on precompilation of packs prior to booting for performance.
|
||||
compile: false
|
||||
|
||||
# Extract and emit a css file
|
||||
extract_css: true
|
||||
|
||||
# Cache manifest.json for performance
|
||||
cache_manifest: true
|
||||
|
||||
docker:
|
||||
<<: *production
|
||||
|
||||
|
@ -15,6 +15,7 @@ services:
|
||||
|
||||
web:
|
||||
build: .
|
||||
image: registry.elbert.us/parsley:latest
|
||||
environment:
|
||||
- RAILS_USE_MEMCACHE=true
|
||||
- RAILS_LOG_TO_STDOUT=true
|
||||
|
19
package.json
19
package.json
@ -1,26 +1,25 @@
|
||||
{
|
||||
"dependencies": {
|
||||
"@rails/webpacker": "^3.5.5",
|
||||
"@rails/webpacker": "4.0.2",
|
||||
"@tweenjs/tween.js": "^17.2.0",
|
||||
"autosize": "^4.0.1",
|
||||
"bulma": "^0.7.2",
|
||||
"caniuse-lite": "^1.0.30000815",
|
||||
"cheerio": "^1.0.0-rc.2",
|
||||
"css-loader": "^0.28.11",
|
||||
"css-loader": "^2.1.0",
|
||||
"lodash": "^4.17.5",
|
||||
"svg-loader": "^0.0.2",
|
||||
"url-loader": "1.0.1",
|
||||
"vue": "^2.5.16",
|
||||
"vue-loader": "^14.2.2",
|
||||
"vue": "^2.5.21",
|
||||
"vue-loader": "^15.4.2",
|
||||
"vue-progressbar": "^0.7.4",
|
||||
"vue-resize": "^0.4.4",
|
||||
"vue-router": "^3.0.1",
|
||||
"vue-template-compiler": "^2.5.16",
|
||||
"vuex": "^3.0.1",
|
||||
"vue-router": "^3.0.2",
|
||||
"vue-template-compiler": "^2.5.21",
|
||||
"vuex": "^3.1.0",
|
||||
"vuex-router-sync": "^5.0.0",
|
||||
"webpack": "^3.11.0"
|
||||
"webpack": "^4.28.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"webpack-dev-server": "^2.11.2"
|
||||
"webpack-dev-server": "^3.1.14"
|
||||
}
|
||||
}
|
||||
|
12
postcss.config.js
Normal file
12
postcss.config.js
Normal file
@ -0,0 +1,12 @@
|
||||
module.exports = {
|
||||
plugins: [
|
||||
require('postcss-import'),
|
||||
require('postcss-flexbugs-fixes'),
|
||||
require('postcss-preset-env')({
|
||||
autoprefixer: {
|
||||
flexbox: 'no-2009'
|
||||
},
|
||||
stage: 3
|
||||
})
|
||||
]
|
||||
}
|
Loading…
Reference in New Issue
Block a user