Gathering detailed insights and metrics for craco-babel-loader
Gathering detailed insights and metrics for craco-babel-loader
Gathering detailed insights and metrics for craco-babel-loader
Gathering detailed insights and metrics for craco-babel-loader
npm install craco-babel-loader
Module System
Min. Node Version
Typescript Support
Node Version
NPM Version
25 Stars
22 Commits
4 Forks
1 Watching
2 Branches
3 Contributors
Updated on 16 Oct 2024
TypeScript (39.06%)
JavaScript (31.69%)
HTML (24.12%)
CSS (5.13%)
Cumulative downloads
Total Downloads
Last day
-9%
3,565
Compared to previous day
Last week
-8.3%
17,917
Compared to previous week
Last month
5.4%
78,376
Compared to previous month
Last year
-30.3%
1,132,190
Compared to previous year
1
2
This is a port of react-app-rewire-babel-loader to CRACO
instead of react-app-rewired. react-app-rewired
was not being updated for version 2 of CRA, and I wanted to use the rewired babel loader with a solution designed for CRA 2.
Rewire
babel-loader
loader in yourcreate-react-app
project usingCRACO
.
Say there is an awesome library you found on npm that you want to use within your un-ejected create-react-app
project, but unfortunately, it's published in ES6+ (since node_modules
doesn't go through babel-loader
), so you cannot really use it. It's also effective for working with monorepos which was my original use case.
However, with CRACO
and this library, craco-babel-loader
, you can use that awesome library you've found.
See below for usage.
1$ yarn add craco-babel-loader 2# npm v5+ 3$ npm install craco-babel-loader 4# before npm v5 5$ npm install --save craco-babel-loader
1// crago.config.js 2// see: https://github.com/sharegate/craco 3 4const path = require("path"); 5const fs = require("fs"); 6 7const rewireBabelLoader = require("craco-babel-loader"); 8 9// helpers 10 11const appDirectory = fs.realpathSync(process.cwd()); 12const resolveApp = relativePath => path.resolve(appDirectory, relativePath); 13 14module.exports = { 15 plugins: [ 16 //This is a craco plugin: https://github.com/sharegate/craco/blob/master/packages/craco/README.md#configuration-overview 17 { plugin: rewireBabelLoader, 18 options: { 19 includes: [resolveApp("node_modules/isemail")], //put things you want to include in array here 20 excludes: [/(node_modules|bower_components)/] //things you want to exclude here 21 //you can omit include or exclude if you only want to use one option 22 } 23 } 24 ] 25} 26
node.js
and npm
. See: https://github.com/creationix/nvm#installationyarn
. See: https://yarnpkg.com/en/docs/installnpm
dependencies. Run: yarn install
yarn run lint
yarn run pretty
yarn run test
yarn run prepublish
yarn run build
MIT.
No vulnerabilities found.
Reason
no dangerous workflow patterns detected
Reason
no binaries found in the repo
Reason
license file detected
Details
Reason
Found 1/22 approved changesets -- score normalized to 0
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
Reason
project is not fuzzed
Details
Reason
branch protection not enabled on development/release branches
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Reason
35 existing vulnerabilities detected
Details
Score
Last Scanned on 2024-11-18
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn Morecraco-babel-loader-plugin
CRACO plugin for babel-loader
craco-esbuild
Use [esbuild](https://github.com/evanw/esbuild) in your [create-react-app](https://create-react-app.dev/) with [craco](https://github.com/gsoft-inc/craco) for faster compilation, development and tests.
babel-loader
babel module loader for webpack
@craco/craco
Create React App Configuration Override, an easy and comprehensible configuration layer for create-react-app.