Skip to content

Commit

Permalink
fix: loading trix editor overwrite in production
Browse files Browse the repository at this point in the history
  • Loading branch information
yksflip committed Aug 23, 2023
1 parent a96f211 commit 1e63c59
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 2 deletions.
2 changes: 1 addition & 1 deletion app/javascript/application.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// Configure your import map in config/importmap.rb. Read more: https://github.com/rails/importmap-rails
import "trix"
import "@rails/actiontext"
import "./trix-editor-overrides"
import "trix-editor-overrides"
1 change: 1 addition & 0 deletions config/importmap.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,3 +2,4 @@
pin "application", preload: true
pin "trix"
pin "@rails/actiontext", to: "actiontext.js"
pin "trix-editor-overrides"

Check failure on line 5 in config/importmap.rb

View workflow job for this annotation

GitHub Actions / test

Layout/TrailingEmptyLines: Final newline missing.
2 changes: 1 addition & 1 deletion config/initializers/assets.rb
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@
# Precompile additional assets.
# application.js, application.css, and all non-JS/CSS in the app/assets
# folder are already added.
Rails.application.config.assets.precompile += %w[application_legacy.js jquery.min.js]
Rails.application.config.assets.precompile += %w[application_legacy.js jquery.min.js trix-editor-overrides.js]

0 comments on commit 1e63c59

Please sign in to comment.