vite_rails 2.0.11 → 3.0.0.beta.2

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
  SHA256:
3
- metadata.gz: 196df1f83a2f6508ee1e8359514be727d98f43f664fdabd66115e16b9093581b
4
- data.tar.gz: 6f1dd12925e16250bb92852294107deb234821b67a252e73eb2025d60a8012e8
3
+ metadata.gz: 49f10c830e43b7b67ad59db279db4ae2002c37db2353d9d8edb8102901a6a4aa
4
+ data.tar.gz: e8d67cd9b719eb36625c67ccffe87234efd8b5246b462c3602ef041c92bbd5b8
5
5
  SHA512:
6
- metadata.gz: 2005d4ab00353cde534027f0b97d372d86786f1dc57b5f73d7c3bcd2e62ac26bc0acd210f103d38cc617fd9eee6b264b0ba8b8edc2916fbf83100af760a8ced7
7
- data.tar.gz: 6ed632c3fc2ae1b3b76867fcc8c15d5eab63622e57bba0e7b0e865bba8b87a814bb0518a879d477b77afe772cf3a9511baa6787e6488d5a31cc98548915dc5de
6
+ metadata.gz: e2127d6b8096054a0223c3c4a11e01b9c10f13f2a1fdd097bcd0794901a9b604db352bbedcaf54bc3209d9a93a70715961ba802a5b1229f3b786e0c911df5f67
7
+ data.tar.gz: 17bc09af3cb48f58c6171bae175c7df2b1936e0059784e537ed5c8f22615aadce3d72249f203db84735818fa72220630ddc63f56d757f9b4422fddd65a61585f
data/CHANGELOG.md CHANGED
@@ -1,5 +1,26 @@
1
+ ## [2.0.13](https://github.com/ElMassimo/vite_ruby/compare/vite_rails@2.0.12...vite_rails@2.0.13) (2021-07-27)
2
+
3
+
4
+ ### Features
5
+
6
+ * Set config.javascript_path so that zeitwerk ignores frontend files ([bab359f](https://github.com/ElMassimo/vite_ruby/commit/bab359f66a5942904e91e2a1a51b440072ba44af))
7
+
8
+
9
+
10
+ ## [2.0.12](https://github.com/ElMassimo/vite_ruby/compare/vite_rails@2.0.11...vite_rails@2.0.12) (2021-05-24)
11
+
12
+
13
+ ### Bug Fixes
14
+
15
+ * Fix typo in comment in example entrypoint in Rails ([78b3104](https://github.com/ElMassimo/vite_ruby/commit/78b3104bc687a79aebd4e0538b8b7c34562cb4eb))
16
+
17
+
18
+
1
19
  ## [2.0.11](https://github.com/ElMassimo/vite_ruby/compare/vite_rails@2.0.10...vite_rails@2.0.11) (2021-05-10)
2
20
 
21
+ ### Refactor
22
+
23
+ * Avoid reference to `dry-cli` during installation, use internal APIs instead ([f5b87e](https://github.com/ElMassimo/vite_ruby/commit/f5b87e69790e48397d15e609b44118e399c9493d))
3
24
 
4
25
 
5
26
  ## [2.0.10](https://github.com/ElMassimo/vite_ruby/compare/vite_rails@2.0.9...vite_rails@2.0.10) (2021-04-21)
data/README.md CHANGED
@@ -43,8 +43,8 @@
43
43
  [heroku]: https://pingcrm-vite.herokuapp.com/
44
44
  [Issues]: https://github.com/ElMassimo/vite_ruby/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc
45
45
  [Discussions]: https://github.com/ElMassimo/vite_ruby/discussions
46
- [no bundling]: https://vitejs.dev/guide/introduction.html#the-problem
47
- [bundling]: https://vitejs.dev/guide/introduction.html#why-bundle-for-production
46
+ [no bundling]: https://vitejs.dev/guide/why.html#the-problems
47
+ [bundling]: https://vitejs.dev/guide/why.html#why-bundle-for-production
48
48
 
49
49
  [Vite] is to frontend tooling as Ruby to programming, pure joy! 😍
50
50
 
@@ -33,4 +33,9 @@ class ViteRails::Engine < Rails::Engine
33
33
  end
34
34
  end
35
35
  end
36
+
37
+ initializer 'vite_rails.set_source' do |app|
38
+ source_dir = ViteRuby.config.root.join(ViteRuby.config.source_code_dir)
39
+ app.config.javascript_path = source_dir.relative_path_from(Rails.root.join('app')).to_s
40
+ end
36
41
  end
@@ -14,6 +14,7 @@ module ViteRails::Installation
14
14
  replace_first_line config.config_path, 'app/frontend', %( "sourceCodeDir": "#{ dir }",)
15
15
  end
16
16
  setup_content_security_policy root.join('config/initializers/content_security_policy.rb')
17
+ append root.join('Procfile.dev'), 'web: bin/rails s'
17
18
  end
18
19
 
19
20
  # Internal: Configure CSP rules that allow to load @vite/client correctly.
@@ -30,7 +31,7 @@ module ViteRails::Installation
30
31
  CSP
31
32
  inject_line_after csp_file, 'policy.script_src', <<~CSP
32
33
  # Allow @vite/client to hot reload changes in development
33
- # policy.script_src *policy.script_src, :unsafe_eval, "http://#{ ViteRuby.config.host_with_port }" if Rails.env.development?
34
+ # policy.script_src *policy.script_src, :unsafe_eval, "http://\#{ ViteRuby.config.host_with_port }" if Rails.env.development?
34
35
  CSP
35
36
  end
36
37
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ViteRails
4
- VERSION = '2.0.11'
4
+ VERSION = '3.0.0.beta.2'
5
5
  end
@@ -0,0 +1 @@
1
+ web: bin/rails server
@@ -6,7 +6,7 @@
6
6
  console.log('Vite ⚡️ Rails')
7
7
 
8
8
  // If using a TypeScript entrypoint file:
9
- // <%= vite_typescript_tag 'application.jsx' %>
9
+ // <%= vite_typescript_tag 'application' %>
10
10
  //
11
11
  // If you want to use .jsx or .tsx, add the extension:
12
12
  // <%= vite_javascript_tag 'application.jsx' %>
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: vite_rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.11
4
+ version: 3.0.0.beta.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Máximo Mussini
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-05-10 00:00:00.000000000 Z
11
+ date: 2021-08-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: railties
@@ -36,14 +36,14 @@ dependencies:
36
36
  requirements:
37
37
  - - "~>"
38
38
  - !ruby/object:Gem::Version
39
- version: '1.0'
39
+ version: 3.0.0.beta.1
40
40
  type: :runtime
41
41
  prerelease: false
42
42
  version_requirements: !ruby/object:Gem::Requirement
43
43
  requirements:
44
44
  - - "~>"
45
45
  - !ruby/object:Gem::Version
46
- version: '1.0'
46
+ version: 3.0.0.beta.1
47
47
  - !ruby/object:Gem::Dependency
48
48
  name: spring
49
49
  requirement: !ruby/object:Gem::Requirement
@@ -75,14 +75,15 @@ files:
75
75
  - lib/vite_rails/installation.rb
76
76
  - lib/vite_rails/tag_helpers.rb
77
77
  - lib/vite_rails/version.rb
78
+ - templates/Procfile.dev
78
79
  - templates/config/rails-vite.json
79
80
  - templates/entrypoints/application.js
80
81
  homepage: https://github.com/ElMassimo/vite_ruby
81
82
  licenses:
82
83
  - MIT
83
84
  metadata:
84
- source_code_uri: https://github.com/ElMassimo/vite_ruby/tree/vite_rails@2.0.11/vite_rails
85
- changelog_uri: https://github.com/ElMassimo/vite_ruby/blob/vite_rails@2.0.11/vite_rails/CHANGELOG.md
85
+ source_code_uri: https://github.com/ElMassimo/vite_ruby/tree/vite_rails@3.0.0.beta.2/vite_rails
86
+ changelog_uri: https://github.com/ElMassimo/vite_ruby/blob/vite_rails@3.0.0.beta.2/vite_rails/CHANGELOG.md
86
87
  post_install_message:
87
88
  rdoc_options: []
88
89
  require_paths:
@@ -94,9 +95,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
94
95
  version: '2.5'
95
96
  required_rubygems_version: !ruby/object:Gem::Requirement
96
97
  requirements:
97
- - - ">="
98
+ - - ">"
98
99
  - !ruby/object:Gem::Version
99
- version: '0'
100
+ version: 1.3.1
100
101
  requirements: []
101
102
  rubygems_version: 3.1.4
102
103
  signing_key: