yfm-transform icon indicating copy to clipboard operation
yfm-transform copied to clipboard

Unnecessary resolve fallback of webpack in runtime version

Open makhnatkin opened this issue 6 months ago • 1 comments

In order for the transform to function properly at runtime, you will need to add some configurations to the webpack resolve fallback.

For example, if you are using CRA, you can do the following:

  1. install CRACO
npm install @craco/craco
  1. Create a file called craco.config.js in the root of the project and add the following configuration:
module.exports = {
  webpack: {
    configure: (webpackConfig) => {
      webpackConfig.resolve.fallback = {
        fs: false,
        process: false,
        path: false,
      };
      return webpackConfig;
    },
  },
};

I would like the installation process of the transform to be as straightforward as possible, without requiring any additional configuration steps for the webpack.

makhnatkin avatar Jul 31 '24 09:07 makhnatkin