Skip to content

A Gatsby4 plugin which parsing assets of public,which is js or css or json or png, upload it to cdn and replace the source[html | app.js | webpackRuntime.js]

License

Notifications You must be signed in to change notification settings

WJmascara/gatsby4-cdn-plugin

Repository files navigation

gatsby4-cdn-plugin

A Gatsby4 plugin which parsing assets of public,which is js | css | json, upload them to cdn and replace the source of html | app.js | webpackRuntime.js

Options

uploader

  • Type: function(filePath):<Promise>
  • Default:
    (filePath) => {
      return Promise.resolve("");
    };
    your cdn upload function with filePath. the funtion return a Promise with final url resolved

About

A Gatsby4 plugin which parsing assets of public,which is js or css or json or png, upload it to cdn and replace the source[html | app.js | webpackRuntime.js]

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published