From 93e720ccb6ba47f98d84b860bc52d2a03d96e67a Mon Sep 17 00:00:00 2001 From: Mostafa Ahangarha Date: Wed, 4 Oct 2023 20:57:19 +0330 Subject: [PATCH] Add file path to the example code --- docs/common-errors.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/common-errors.md b/docs/common-errors.md index 752fe63c..e0d1a02e 100644 --- a/docs/common-errors.md +++ b/docs/common-errors.md @@ -58,6 +58,7 @@ you need to specify a matching pattern in `appllication.js` and `server_renderin For example, see the below code: ```js +// app/javascript/packs/application.js const componentRequireContext = require.context('react_rails_components', true, /^(?!.*\.test)^\.\/.*$/) const ReactRailsUJS = require('react_ujs') ReactRailsUJS.useContext(componentRequireContext)