Module: Lanes::API::HelperMethods
- Defined in:
- lib/lanes/api/helper_methods.rb
Instance Method Summary collapse
Instance Method Details
#client_bootstrap_data ⇒ Object
6 7 8 |
# File 'lib/lanes/api/helper_methods.rb', line 6 def client_bootstrap_data Oj.dump(Extensions.client_bootstrap_data(self), mode: :compat) end |
#csrf_token ⇒ Object
10 11 12 |
# File 'lib/lanes/api/helper_methods.rb', line 10 def csrf_token Rack::Csrf.csrf_token(env) end |
#data ⇒ Object
18 19 20 |
# File 'lib/lanes/api/helper_methods.rb', line 18 def data @json_data ||= Oj.load( request.body.read ) end |
#lanes_api_url ⇒ Object
14 15 16 |
# File 'lib/lanes/api/helper_methods.rb', line 14 def lanes_api_url Lanes.config.mounted_at end |