You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
minor #12035 Instructions to prevent CORS for Hot Module Replacement (lambertbeekhuis)
This PR was submitted for the 4.3 branch but it was merged into the 3.4 branch instead (closes#12035).
Discussion
----------
Instructions to prevent CORS for Hot Module Replacement
<!--
If your pull request fixes a BUG, use the oldest maintained branch that contains
the bug (see https://symfony.com/roadmap for the list of maintained branches).
If your pull request documents a NEW FEATURE, use the same Symfony branch where
the feature was introduced (and `master` for features of unreleased versions).
-->
Commits
-------
a68e133 Adding instructions to prevent CORS errors
Copy file name to clipboardExpand all lines: frontend/encore/dev-server.rst
+19Lines changed: 19 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -39,5 +39,24 @@ option:
39
39
HMR currently works for :doc:`Vue.js </frontend/encore/vuejs>`, but does *not* work
40
40
for styles anywhere at this time.
41
41
42
+
For Hot Module Replacement, CORS-errors can appear (Cross Origin Resource Sharing). To handle this, add the --disable-host-check and --port options to your command:
43
+
44
+
.. code-block:: terminal
45
+
46
+
$ yarn encore dev-server --port 8080 --disable-host-check --hot
47
+
48
+
Or, alternatively, you can add the options to your package.json
0 commit comments