Commit ffe50a1e authored by PiTrem's avatar PiTrem
Browse files

sprocket added manifest config

rm unecessary assets config

quiet assets as assets config option with sprocket-rails >3
rm gem quiet_assets

disable uglifier compiler
enable sass compressor

rename jsx file to js

turbosprocket default config

remove turbolink

upd_jquery-rails

appli.scss use import
parent 7c5572b5
......@@ -11,6 +11,9 @@ gem 'sass-rails', '~> 5.0', '>= 5.0.6'
# Use Uglifier as compressor for JavaScript assets
gem 'uglifier', '>= 4.0.0'
gem 'turbo-sprockets-rails4'
# Twitter bootstrap styles
gem 'bootstrap-sass', '~> 3.3.5'
# Use jquery as the JavaScript library
......@@ -30,8 +33,8 @@ gem 'rinchi-gem', '1.0.1', git: 'https://git.scc.kit.edu/ComPlat/rinchi-gem.git'
gem 'bibtex-ruby'
group :development do
gem 'turbo-sprockets-rails4'
gem 'rack-mini-profiler', git: 'https://github.com/MiniProfiler/rack-mini-profiler'
gem 'better_errors' # allows to debug exception on backend from browser
......@@ -173,9 +176,6 @@ group :development, :test do
# RailsPanel Chrome extension
gem 'meta_request'
# Remove all assets requests
gem 'quiet_assets'
gem 'capistrano', '3.9.1'
gem 'capistrano-bundler'
gem 'capistrano-npm'
......
......@@ -203,7 +203,7 @@ GEM
coercible (1.0.0)
descendants_tracker (~> 0.0.1)
colored (1.2)
concurrent-ruby (1.0.5)
concurrent-ruby (1.1.3)
countries (2.0.8)
i18n_data (~> 0.7.0)
money (~> 6.7)
......@@ -326,7 +326,7 @@ GEM
jbuilder (2.4.1)
activesupport (>= 3.0.0, < 5.1)
multi_json (~> 1.2)
jquery-rails (4.1.1)
jquery-rails (4.3.3)
rails-dom-testing (>= 1, < 3)
railties (>= 4.2.0)
thor (>= 0.14, < 2.0)
......@@ -344,7 +344,7 @@ GEM
rb-fsevent (~> 0.9, >= 0.9.4)
rb-inotify (~> 0.9, >= 0.9.7)
ruby_dep (~> 1.2)
loofah (2.2.2)
loofah (2.2.3)
crass (~> 1.0.2)
nokogiri (>= 1.5.9)
mail (2.7.0)
......@@ -388,7 +388,7 @@ GEM
net-sftp (2.1.2)
net-ssh (>= 2.6.5)
net-ssh (4.2.0)
nokogiri (1.8.2)
nokogiri (1.8.5)
mini_portile2 (~> 2.3.0)
numerizer (0.1.1)
open4 (1.3.4)
......@@ -420,9 +420,7 @@ GEM
public_suffix (2.0.5)
pundit (1.1.0)
activesupport (>= 3.0.0)
quiet_assets (1.1.0)
railties (>= 3.1, < 5.0)
rack (1.6.10)
rack (1.6.11)
rack-accept (0.4.5)
rack (>= 0.4)
rack-contrib (1.5.0)
......@@ -687,7 +685,6 @@ DEPENDENCIES
prawn
prawn-svg
pundit
quiet_assets
rack-mini-profiler!
rails (= 4.2.10)
rinchi-gem (= 1.0.1)!
......
//= link_tree ../fonts
//= link_tree ../images
//= link_directory ../javascripts .js
//= link_directory ../stylesheets .css
......@@ -14,7 +14,6 @@
//= require jquery.caret
//= require jquery_ujs
//= require autocomplete.min
//= //require turbolinks
//= require polyfill
//= require components
//= require bootstrap
......
......@@ -16,7 +16,7 @@ import ReactionDetailsMainProperties from './ReactionDetailsMainProperties';
import MaterialGroupContainer from './MaterialGroupContainer';
import QuillEditor from './QuillEditor';
import Sample from './models/Sample';
import StringTag from './StringTag.jsx';
import StringTag from './StringTag';
import { observationPurification, solventsTL } from './utils/reactionPredefined';
function dummy() { return true; }
......
......@@ -12,14 +12,13 @@
*
*= require_tree .
*= require_self
*= require autocomplete
*/
@import "bootstrap-sprockets";
@import "bootstrap";
@import "icons";
@import "font-awesome";
@import "autocomplete";
<%Bundler.load.current_dependencies.select{|dep| dep.groups.include?(:plugins)}.map(&:name).each do |plugin|%>
@import "<%=plugin%>";
......
......@@ -23,7 +23,7 @@ module Chemotion
config.version = File.exist?('VERSION') && YAML.load_file('VERSION') ||
{ 'version': 'v0', 'base_revision': '0', 'current_revision': '0' }
config.version['current_revision'] = File.read('REVISION') if File.exist?('REVISION')
config.action_dispatch.perform_deep_munge = false
# Grape API config
config.paths.add File.join('app', 'api'), glob: File.join('**', '*.rb')
......
......@@ -28,6 +28,9 @@ Rails.application.configure do
# yet still be able to expire them through the digest params.
config.assets.digest = true
# Turns off the Rails asset pipeline log (suppresses output of asset requests).
config.assets.quiet = true
# Adds additional error checking when serving assets at runtime.
# Checks for improperly declared sprockets dependencies.
# Raises helpful error messages.
......
......@@ -27,8 +27,8 @@ Rails.application.configure do
config.serve_static_files = true
# Compress JavaScripts and CSS.
config.assets.js_compressor = Uglifier.new(harmony: true)
# config.assets.css_compressor = :sass
# config.assets.js_compressor = Uglifier.new(harmony: true)
config.assets.css_compressor = :sass
# Do not fallback to assets pipeline if a precompiled asset is missed.
config.assets.compile = true
......@@ -39,6 +39,13 @@ Rails.application.configure do
# `config.assets.precompile` and `config.assets.version` have moved to config/initializers/assets.rb
TurboSprockets.configure do |config|
config.precompiler.enabled = false
config.preloader.enabled = false
config.preloader.worker_count = 2
config.precompiler.worker_count = 2
end
# Specifies the header that your server uses for sending files.
# config.action_dispatch.x_sendfile_header = 'X-Sendfile' # for Apache
# config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for NGINX
......
......@@ -9,5 +9,6 @@ Rails.application.config.assets.version = '1.0'
# Precompile additional assets.
# application.js, application.css, and all non-JS/CSS in app/assets folder are already added.
Rails.application.config.assets.precompile << /\.(?:svg|eot|woff|ttf)\z/
Rails.application.config.assets.precompile += %w( affiliations.js affiliation.js)
# Rails.application.config.assets.precompile << /\.(?:svg|eot|woff|ttf)\z/
# Rails.application.config.assets.precompile += %w( affiliations.js affiliation.js)
Rails.application.config.assets.precompile = %w( manifest.js )
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment