-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Make secret key base mandatory * remove path option to local gem in examples * Fix todos hotwire e2e tests * Refactor singleton methods
- Loading branch information
Showing
16 changed files
with
44 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,13 @@ | ||
# frozen_string_literal: true | ||
|
||
if ENV['SECRET_KEY_BASE'].nil? | ||
raise StandardError, <<~ERROR | ||
SECRET_KEY_BASE environment variable is required | ||
Provide ENV['SECRET_KEY_BASE'] in your file or export the variable to your profile | ||
ERROR | ||
end | ||
|
||
require "rails" | ||
require_relative "uni_rails/version" | ||
require_relative "uni_rails/helpers" | ||
|
@@ -29,9 +37,9 @@ def self.enable_turbo_rails! | |
end | ||
end | ||
|
||
UniRails::App::Javascript.dependencies = { | ||
App::Javascript.dependencies.merge!( | ||
"turbo" => "https://unpkg.com/@hotwired/[email protected]/dist/turbo.es2017-umd.js" | ||
} | ||
) | ||
end | ||
|
||
def self.rackup_handler=(handler) | ||
|
@@ -58,7 +66,7 @@ def self.run(**webrick_options) | |
end | ||
|
||
def self.import_maps(dependencies) | ||
UniRails::App::Javascript.dependencies = dependencies | ||
UniRails::App::Javascript.dependencies.merge! dependencies | ||
end | ||
|
||
def self.javascript(content) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,10 @@ | ||
# frozen_string_literal: true | ||
|
||
ENV['SECRET_KEY_BASE'] = 'something' | ||
|
||
$LOAD_PATH.unshift File.expand_path("../lib", __dir__) | ||
require "uni_rails" | ||
|
||
require "minitest/autorun" | ||
require "debug" | ||
|