New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

babel-plugin-webpack-prefetch

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

babel-plugin-webpack-prefetch

babel plugin for adding webpackPrefetch comment

  • 1.1.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

babel-plugin-webpack-prefetch

Babel plugin for adding webpackPrefetch comment.

license npm Build Status codecov Conventional Commits

Usage

yarn add -D babel-plugin-webpack-prefetch

then add babel-plugin-webpack-prefetch to your .babelrc

{
  "plugins": [
+    "babel-plugin-webpack-prefetch"
  ]
}

And it does :

import ccc from 'ddd'
import 'aaa'

const a = import(
+ /* webpackPrefetch: true */
'aaa'
)
const b = import(
+ /* webpackPrefetch: true */
'bbb'
)

babel-plugin-webpack-prefetch will respect your comment :

const a = import(
// you added webpackPrefetch: false so babel-plugin-webpack-prefetch will not modify it
/* webpackPrefetch: false */
'aaa'
)
const b = import(
+ /* webpackPrefetch: true */
'bbb'
)

Keywords

FAQs

Package last updated on 25 Apr 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc