Skip to content

wheeler/codemods-and-linters

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

codemods-and-linters

Codemods and eslint rules written by me, @wheeler.

jscodeshift

Codemod Examples

bugnsag4.js - Helper to convert Bugsnag.notify "handled" calls from v3 format to v4 format

findReactModal.js - remove a wrapping function call and its import.

stateless_modal_to_react_modal.js - Replace one JSX component with another and change one prop name.

static_property_placement.js - Extract React static properties from inside the class static foo to below Class.foo = . Helps adopt current eslint-config-airbnb@18 rules.

redirect_migration.js - Replace a homegrown Redirect component with Redirect from react-router-dom. Updates imports, modifies rrd import if existing, swaps a homegrown redirect prop for rrd's opposite push prop.

Resources

Typescript Definitions

helpful for understanding available methods, params, returns, some contain descriptions.

Docs

https://rawgit.com/facebook/jscodeshift/master/docs/Collection.html - descriptions of some core functionality

eslint-configs

Some eslint configs I have written or used.

About

Codemods and eslint rules written by @wheeler

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published