Skip to content

Commit b2f238a

Browse files
committed
minor #8674 Reduce ambiguity of encore installation (mahalay, weaverryan)
This PR was submitted for the master branch but it was merged into the 3.3 branch instead (closes #8674). Discussion ---------- Reduce ambiguity of encore installation Commits ------- 514cdb9 Adding yarn install text b852a98 Reduce ambiguity of encore installation
2 parents d3636de + 514cdb9 commit b2f238a

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

frontend/encore/installation.rst

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,16 +11,23 @@ Then, install Encore into your project with Yarn:
1111
1212
.. note::
1313

14-
If you want to use `npm`_ instead of `yarn`_, replace ``yarn add xxx --dev`` by
15-
``npm install xxx --save-dev``.
14+
If you want to use `npm`_ instead of `yarn`_:
15+
16+
.. code-block:: terminal
17+
18+
$ npm install @symfony/webpack-encore --save-dev
1619
1720
.. tip::
1821

19-
If you are using Flex for your project, you can install Encore via:
22+
If you are using Flex for your project, you can initialize your project for Encore via:
2023

2124
.. code-block:: terminal
2225
2326
$ composer require encore
27+
$ yarn install
28+
29+
This will create a ``webpack.config.js`` file, add the ``assets/`` directory, and add ``node_modules/`` to
30+
``.gitignore``.
2431

2532
This command creates (or modifies) a ``package.json`` file and downloads dependencies
2633
into a ``node_modules/`` directory. When using Yarn, a file called ``yarn.lock``

0 commit comments

Comments
 (0)