File: hello_erb.js.erb

package info (click to toggle)
ruby-webpacker 5.4.3-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 1,472 kB
  • sloc: ruby: 1,626; javascript: 1,480; makefile: 4
file content (6 lines) | stat: -rw-r--r-- 287 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
// Run this example by adding <%%= javascript_pack_tag 'hello_erb' %> to the head of your layout file,
// like app/views/layouts/application.html.erb. Don't forget to uncomment erb tag after adding it to your layout file.

<% name = 'Erb' %>

console.log('Hello world from <%= name %>')