From 0657327e2098a9ee59444900e27369c3b0041044 Mon Sep 17 00:00:00 2001 From: Petrik Date: Fri, 11 Feb 2022 21:06:27 +0100 Subject: [PATCH] Fix javascript example code block [ci-skip] Linebreaks are required before code blocks. --- guides/source/working_with_javascript_in_rails.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/guides/source/working_with_javascript_in_rails.md b/guides/source/working_with_javascript_in_rails.md index 469dcfb949..1a4377ed80 100644 --- a/guides/source/working_with_javascript_in_rails.md +++ b/guides/source/working_with_javascript_in_rails.md @@ -42,6 +42,7 @@ $ bin/importmap pin react react-dom ``` Then, import the package into `application.js` as usual: + ```javascript import React from "react" import ReactDOM from "react-dom" @@ -57,7 +58,8 @@ bundling, you can create new Rails applications with your choice of To use a bundler instead of import maps in a new Rails application, pass the `—javascript` or `-j` option to `rails new`: -``` + +```bash $ rails new my_new_app --javascript=webpack OR $ rails new my_new_app -j webpack