From 3d4a117c914770855cad23724c272109ebb9cbd1 Mon Sep 17 00:00:00 2001 From: jaywcjlove Date: Sat, 9 Jul 2022 02:47:47 +0000 Subject: [PATCH] deploy: 7192c188ed8d481a74f298e8464fc9c69d9fafc0 --- badges.svg | 35 ++-- index.html | 368 +++++++++++++++++++++++++------------- lcov-report/index.html | 2 +- lcov-report/index.js.html | 2 +- 4 files changed, 260 insertions(+), 147 deletions(-) diff --git a/badges.svg b/badges.svg index d7a99220..4354a36c 100644 --- a/badges.svg +++ b/badges.svg @@ -1,23 +1,20 @@ - - + coverage: 100% - - - + + + - - - - - - - + + + + + - - - coverage - - 100% + - - \ No newline at end of file + + \ No newline at end of file diff --git a/index.html b/index.html index 01a76b34..8d374de9 100644 --- a/index.html +++ b/index.html @@ -6,38 +6,115 @@ - - - -
-

babel-plugin-transform-remove-imports

-

- NPM version - Build and Test - Coverage Status - Downloadss -

-

Modular import plugin for babel for server-side rendering. Also works for cjs to delete imported CSS to avoid compilation errors..

-

Usage

-
npm install babel-plugin-transform-remove-imports --save-dev
-
+

babel-plugin-transform-remove-imports

+

+ NPM version + Build and Test + Coverage Status + Downloadss + Repo Dependents +

+

Modular import plugin for babel for server-side rendering. Also works for cjs to delete imported CSS to avoid compilation errors..

+

Usage

+
npm install babel-plugin-transform-remove-imports --save-dev
+
-

Via .babelrc or babel-loader.

-
{
-  "plugins": [
-    [
-      "babel-plugin-transform-remove-imports", {
-        "test": "\\.(less|css)$"
-      }
-    ]
-  ]
-}
-
{ + "plugins": [ + [ + "babel-plugin-transform-remove-imports", { + "test": "\\.(less|css)$" + } + ] + ] +} +

Support require

-

Via .babelrc or babel-loader.

-
{
-  "plugins": [
-    [
-      "babel-plugin-transform-remove-imports", {
-        "test": "@babel/core",
-      }
-    ]
-  ]
-}
-
Support require +

Via .babelrc or babel-loader.

+
{
+  "plugins": [
+    [
+      "babel-plugin-transform-remove-imports", {
+        "test": "@babel/core",
+      }
+    ]
+  ]
+}
+

Options

-
    -
  • test: RegExp | string | (RegExp | string)[]
  • -
-

- A regular expression to match the imports that will be removed. - It could be a string or a RegExp object. - You could also pass an array here. -

-
    -
  • removeAll: boolean
  • -
-

Deletes all imports.

-
    -
  • remove?: 'effects'
  • -
-

Removing only side effects imports,Used with the test option. #3

-
// Input Code
-import 'foo';
-import Foo from 'foo';
-
-// Output Code  ↓ ↓ ↓ ↓ ↓ ↓
-import Foo from 'foo';
-
Options +
    +
  • test: RegExp | string | (RegExp | string)[]
  • +
+

+ A regular expression to match the imports that will be removed. + It could be a string or a RegExp object. + You could also pass an array here. +

+
    +
  • removeAll: boolean
  • +
+

Deletes all imports.

+
    +
  • remove?: 'effects'
  • +
+

Removing only side effects imports,Used with the test option. #3

+
// Input Code
+import 'foo';
+import Foo from 'foo';
+
+// Output Code  ↓ ↓ ↓ ↓ ↓ ↓
+import Foo from 'foo';
+
-

Programmatic Usage

-
import plugin from 'babel-plugin-transform-remove-imports'
-import { transform } from 'babel-core'
- 
-function replace (code) {
-  return transform(code, {
-    babelrc: false,
-    plugins: [
-      [plugin, { test: /\.(less|css)$/ }]
-    ],
-  }).code;
-}
- 
-replace("import './index.main.less';import { Button } from 'uiw';")
-//=> "import { Button } from 'uiw';"
-
Programmatic Usage +
import plugin from 'babel-plugin-transform-remove-imports'
+import { transform } from 'babel-core'
+ 
+function replace (code) {
+  return transform(code, {
+    babelrc: false,
+    plugins: [
+      [plugin, { test: /\.(less|css)$/ }]
+    ],
+  }).code;
+}
+ 
+replace("import './index.main.less';import { Button } from 'uiw';")
+//=> "import { Button } from 'uiw';"
+

Contributors

-

As always, thanks to our amazing contributors!

-

Made with github-action-contributors.

-

License

-

MIT Β© Kenny Wong & Slava Fomin II

- - -
- +

Contributors

+

As always, thanks to our amazing contributors!

+

Made with github-action-contributors.

+

License

+

MIT Β© Kenny Wong & Slava Fomin II

+ diff --git a/lcov-report/index.html b/lcov-report/index.html index 559be386..a26e7a37 100644 --- a/lcov-report/index.html +++ b/lcov-report/index.html @@ -101,7 +101,7 @@

All files