Rails 7 RC1 updates
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
//= link_tree ../images
|
||||
//= link_directory ../stylesheets .css
|
||||
//= link_tree ../../javascript .js
|
||||
//= link_tree ../../../vendor/javascript .js
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
// Configure your import map in config/importmap.rb. Read more: https://github.com/rails/importmap-rails
|
||||
import "controllers"
|
||||
import "@hotwired/turbo-rails"
|
||||
import "controllers"
|
||||
|
||||
console.log('Hello World from application.js');
|
||||
|
||||
@@ -3,9 +3,8 @@ import { Application } from "@hotwired/stimulus"
|
||||
const application = Application.start()
|
||||
|
||||
// Configure Stimulus development experience
|
||||
application.warnings = true
|
||||
application.debug = false
|
||||
window.Stimulus = application
|
||||
application.debug = false
|
||||
window.Stimulus = application
|
||||
|
||||
export { application }
|
||||
|
||||
|
||||
@@ -1,5 +1,11 @@
|
||||
// Import and register all your controllers from the importmap under controllers/*
|
||||
|
||||
import { application } from "controllers/application"
|
||||
import { registerControllersFrom } from "@hotwired/stimulus-importmap-autoloader"
|
||||
registerControllersFrom("controllers", application)
|
||||
|
||||
// Eager load all controllers defined in the import map under controllers/**/*_controller
|
||||
import { eagerLoadControllersFrom } from "@hotwired/stimulus-loading"
|
||||
eagerLoadControllersFrom("controllers", application)
|
||||
|
||||
// Lazy load controllers as they appear in the DOM (remember not to preload controllers in import map!)
|
||||
// import { lazyLoadControllersFrom } from "@hotwired/stimulus-loading"
|
||||
// lazyLoadControllersFrom("controllers", application)
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
<html>
|
||||
<head>
|
||||
<title>Railsondocker</title>
|
||||
<meta name="viewport" content="width=device-width,initial-scale=1">
|
||||
<%= csrf_meta_tags %>
|
||||
<%= csp_meta_tag %>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user