1.0.12 ā€¢ Published 2 years ago

dev-react-lib v1.0.12

Weekly downloads
-
License
MIT
Repository
-
Last release
2 years ago

dev-react-lib

A really fast utility to start to develop your library for React and (if you want) publish it!

šŸ’» Just write your code without bundlers configurations!

šŸ“¦ Essential packages for a fast installation!

šŸ‘ Test your lib directly in your browser thanks to Parcel!

āš”ļø Fast build process thanks to babel!

ā³ Changes and testing in real time!

Table of contents

Status

npm NPM npm publish size npm install size

Quick start

Just by running the command

npx dev-react-lib

When finished, a folder will be created with the name of your project

Enter the folder by running the command:

cd my-new-lib

you have the following directory structure:

./src/lib/index.js - The core of your library

./src/index.html - Served html page to test your library
./src/index.js - Served .js file to test your library

./lib - Finish bundle of your library

Watch

You can start wathing your library file by running the following command:

npm run start

or:

yarn start

Edit

Now try to edit the file:

./src/lib/index.js

Babel will look at the changes and create a bundle in the ./lib folder

Build

npm run build

or:

yarn build

Test

Thanks to Parcel bundler, you can test your library by running the command:

npm run test

or:

yarn test

Parcel will open your browser and will serve your library at

http://localhost:1234

You can edit the served files if you want:

./src/index.html
./src/index.js

Publish

In the package.json of your newly created library it has already been specified that only the library folder must be contained in the package.

You can test the contents of the package before sending it by running the command:

npm pack

or

yarn pack

This command will create a package only the necessary files.

When you are ready, you can publish it just running the command:

npm publish

or

yarn publish

Contributing

If you liked this application and would like to contribute you can do it by buying me a coffee ā˜•ļø

Copyright and license

Copyright 2022 Gianfilippo Balestriero.

Code released under the MIT License.

1.0.12

2 years ago

1.0.11

2 years ago

1.0.10

2 years ago

1.0.9

2 years ago

1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago