ace-rails-ap 4.0.2 → 4.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 8192dcb30d1d6d1a71a923f70f1df01298481610
4
- data.tar.gz: b215929038eafedb1002945cda5911c575f9225f
3
+ metadata.gz: 5cb558b595c4128e67670f5e0b5d47dbc08c3a9b
4
+ data.tar.gz: 1387d4eb3a9de97ed63701df3064282f3696c0ea
5
5
  SHA512:
6
- metadata.gz: 28e248efecbd78c0f27be9149965d35c06aaa04bf4a3d96cf5a1f3c4e93f01450911705ea8657ca2b219178fd99f8bcb48d6c6170a06dc51de8d979b89b43e95
7
- data.tar.gz: 800f8749652f1851ae227b8c199b3d9dc827c9c7ebd990c9e62231be76afc448c207fe8d668c10d4ca25a6a93011ef8b43ba1cba399d9eb0ee05aaf47f798b0b
6
+ metadata.gz: 38cff89ec6c3e3b64d7a373af565ce67971834fb1ef66c7aa164c10379941248e01502928997ca27d9138766516f44c11fe463bfb79d0b45abf1efdb32d77418
7
+ data.tar.gz: fca63b61d19a2b58b333b2dfad7b5d6a8ab98025a88f94e36287171c46d762c09f9cddc154f875a8c413e1484f676b871f2f0b5e509ea0db1766d6694a7f02b4
data/README.md CHANGED
@@ -26,13 +26,14 @@ To include a theme or mode, add them in your application.js file:
26
26
  //= require ace/mode-somemode
27
27
  ```
28
28
 
29
- Do not include Ace workers files in your application.js file. Then just use Ace like normal.
29
+ Workers and modes don't need to be included in your application.js file, as they can also be loaded dynamically (see below).
30
30
 
31
31
  ## Rails Asset Pipeline
32
32
 
33
- Ace editor will dynamically load in run-time the workers javascript files.
34
- ace-rails-ap play nice with rails asset pipeline by automatically configuring the precompilation of the workers files,
35
- and by setting-up Ace to load the fingerprinted worker files. You have nothing to do, it just works.
33
+ Ace will dynamically load the JavaScript files for workers and modes at run-time.
34
+
35
+ ace-rails-ap plays nicely with the Rails asset pipeline by automatically configuring the precompilation of the workers and modes,
36
+ and by setting up Ace to load the fingerprinted files. You have nothing to do, it just works.
36
37
 
37
38
  ## Migrate from previous version of ace-rails-ap
38
39
 
@@ -41,5 +42,3 @@ You may have done some customisation to allow ace-rails-ap to work in production
41
42
 
42
43
  Also replace the previous javascript manifest instruction `//= require ace/ace` by the new `//= require ace-rails-ap`, and remove
43
44
  all workers from your javascript manifest.
44
-
45
-
@@ -2,7 +2,7 @@ module Ace
2
2
  module Rails
3
3
  class Engine < ::Rails::Engine
4
4
  initializer 'ace-rails-ap.assets.precompile' do |app|
5
- app.config.assets.precompile += %w[ace/worker-*.js]
5
+ app.config.assets.precompile += %w[ace/worker-*.js ace/mode-*.js]
6
6
  end
7
7
  end
8
8
  end
@@ -1,5 +1,5 @@
1
1
  module Ace
2
2
  module Rails
3
- VERSION = "4.0.2"
3
+ VERSION = "4.1.0"
4
4
  end
5
5
  end
@@ -2,4 +2,8 @@ ace.config.set('basePath', '/assets/ace');
2
2
  <% Dir[File.dirname(__FILE__) + '/ace/worker-*.js'].each do |file| %>
3
3
  <% worker = File.basename(file, '.js').sub(/^worker-/, '') %>
4
4
  ace.config.setModuleUrl("ace/mode/<%= worker %>_worker", "<%= asset_path "ace/worker-#{worker}.js" %>");
5
- <% end %>
5
+ <% end %>
6
+ <% Dir[File.dirname(__FILE__) + '/ace/mode-*.js'].each do |file| %>
7
+ <% mode = File.basename(file, '.js').sub(/^mode-/, '') %>
8
+ ace.config.setModuleUrl("ace/mode/<%= mode %>", "<%= asset_path "ace/mode-#{mode}.js" %>");
9
+ <% end %>
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ace-rails-ap
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.2
4
+ version: 4.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Cody Krieger
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-02-24 00:00:00.000000000 Z
11
+ date: 2016-07-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler