GitShow/kentcdodds/babel-plugin-macros
kentcdodds

babel-plugin-macros

๐ŸŽฃ Allows you to build simple compile-time libraries

by kentcdodds
babelbabel-macrosbabel-plugin
Star on GitHubForkWebsitenpm

JavaScript

2.6k stars138 forks54 contributorsQuiet ยท 3y agoSince 2017v3.1.0MIT

Meet the team

See all 54 on GitHub โ†’
allcontributors[bot]Bot
allcontributors[bot]15 contributions
tricoder42
tricoder428 contributions
conartist6
conartist65 contributions
kentcdodds
kentcdodds5 contributions
Andarist
Andarist4 contributions
InvictusMB
InvictusMB3 contributions
sergeysova
sergeysova2 contributions
jiiinCho
jiiinCho2 contributions

Languages

View on GitHub โ†’
JavaScript100%

Commit activity

Last 12 weeks ยท 0 commits

Full graph โ†’

Community health

6 of 6 standards met

Community profile โ†’
85
โœ“READMEโœ“Licenseโœ“Contributingโœ“Code of Conductโœ“Issue Templateโœ“PR Template

Recent PRs & issues

Quiet ยท 3 in progress ยท Last activity 3y ago
See all on GitHub โ†’
kentcdodds
Maintenance is frozenOpenIssue

I'm no longer watching this repo. This babel plugin is pretty much done and I'm no longer using it much. If you really need something changed, then I suggest you fork it. Unfortunately, this plugin is so widely used that it would be irresponsible for me to hand over publish rights to someone I don't know and trust. So I'm basically freezing development unless someone who fits that description wants to take it over. I might be willing to accept a PR to keep this project up-to-date for compatibility reasons with babel. But in general, there's no more maintenance that will happen on this package. Thanks for understanding.

kentcdodds ยท 1mo ago
TrySound
refactor: replace cosmiconfig with lilconfigOpenPR

What: cosmiconfig is a massive package which recently got a small alternative without dependencies lilconfig. https://github.com/antonk52/lilconfig https://packagephobia.com/result?p=cosmiconfig https://packagephobia.com/result?p=lilconfig Though still a big part of cosmiconfig is package. https://packagephobia.com/result?p=yaml This package is important piece of relay and emotion. Would be good to make it as small as possible. Why: Node modules are bloated with large dependencies. I'm trying to help with this. How: Just switch to alternative. Checklist: [ ] Documentation [x] Tests [x] Ready to be merged

TrySound ยท 4mo ago
bjnewman
feat!: modernize to ESM-only with Node 22+ minimumOpenPR

Summary As discussed, this grew from the original lilconfig migration into a full modernization pass. Happy to break it up if you'd prefer smaller pieces, but everything here felt like it belonged together. Breaking change: This package is now ESM-only and requires Node.js >= 22. What changed Converted from CJS to ESM (/, ) Replaced cosmiconfig with lilconfig + yaml for config loading Replaced kcd-scripts with ESLint 10 (flat config), Prettier 3, Vitest 4, Husky 9, lint-staged Added config file variants so users with projects can still write CJS configs Renamed all CJS test fixtures and mock modules from to Migrated tests from Jest to Vitest โ€” 34 tests passing, fixed some assertions that weren't actually testing what they looked like they were testing Modernized CI: Node 22/24 matrix, latest GitHub Actions, codecov v5 coverage, semantic-release v25 Updated all docs with ESM examples and the Node 22+ requirement Dropped (replaced with ), (unused), and old babel-es2015 plugin Why Node 22? Per your suggestion โ€” Babel 7 loads plugins via , and Node 22.12+ supports natively, so going ESM-only doesn't require a build step. Notes kept at v10 for now โ€” v11/v12 changed how is resolved in a way that may conflict with fixture paths. Worth upgrading separately. kept at ^1.x โ€” still needed for custom extension resolution (, , ) Test plan [x] passes (lint + format + 34/34 tests) [x] generates v8 coverage [x] ESM import and CJS require both work on Node 22+ [x] CI tests against Node 22 and 24 Summary by CodeRabbit Breaking Changes ESM-only release: requires Node.js โ‰ฅ 22 and updates public exports (modern ESM-style API). New Features Config discovery now supports YAML and .cjs variants. Testing moved to Vitest; pre-commit lint/format hooks added. Documentation Examples and guides updated to ESM import/export and lilconfig guidance. Links updated to point to main branch. Chores** Modernized tooling, scripts, linting/formatting and CI workflows.

bjnewman ยท 5mo ago

Recent fixes

View closed PRs โ†’
fs-projects
Facing issue with fortawesome integration with babel-plugin-macros.ClosedIssue

I have raised the bug in fortawesome repo. https://github.com/FortAwesome/react-fontawesome/issues/554 Please help me fix these warnings as it's not allowing me to compile my code.

fs-projects ยท 2y ago
AbeykoonOshan
Can we bump "cosmiconfig" dependency to its latestClosedIssue

As per the recent snyk reports the yaml package has a security vulnerability. Snyk issue: https://security.snyk.io/vuln/SNYK-JS-YAML-5458867 But this is fixed in latest version of yaml. For the moment babel-plugin-macro library is dependant on "cosmiconfig@7.0.0" which has another dependency to "yaml@1.10.0". But the newer version of "cosmiconfig" doesn't use "yaml" as a dependency so if we can bump up "cosmiconfig" to its latest it will be helpful. I am not sure that how much of vulnerable features of "yaml" is used in "cosmoconfig" and how it can affect this package, just creating this issue for the library to evaluate this issue and fix this if its possible.

AbeykoonOshan ยท 3y ago
muskankhedia
Updated the version for cosmiconfig packageMergedPR

What: Updated the version for cosmiconfig package Why: The lower versions of cosmiconfig package contains yaml which have started reporting the vulnerability issues. How: Updated the package version from to Checklist: [ ] Documentation [ ] Tests [ ] Ready to be merged

muskankhedia ยท 3y ago
Structured data for AI agents

Repository: kentcdodds/babel-plugin-macros. Description: ๐ŸŽฃ Allows you to build simple compile-time libraries Stars: 2633, Forks: 138. Primary language: JavaScript. Languages: JavaScript (100%). License: MIT. Homepage: https://npm.im/babel-plugin-macros Topics: babel, babel-macros, babel-plugin. Latest release: v3.1.0 (5y ago). Open PRs: 3, open issues: 9. Last activity: 3y ago. Community health: 85%. Top contributors: allcontributors[bot], tricoder42, conartist6, kentcdodds, Andarist, InvictusMB, sergeysova, jiiinCho, stevemao, MichaelDeBoey and others.

ยท@ofershap

Replace github.com with gitshow.dev