So lately I published my first npm package.
It gave me immense joy to share it with you here.
But it's not something I was planning to do. Things happen you know.
Quickly and unexpectedly.
I was working on a MEAN stack project for the last 2-3 months. When working on the backed of stuff, I was going on creating files and doing the same or somewhat same set of codes over and over again.
If it's something related to user, then the file name of the controller is user.controller.js and the service file name is user.service.js. With method, names are getUser, or getUsers, or deleteUser.
And if it's on some other stuff, say a device, most of the logic remains the same, except this time the name of the method and files changes to deleteDevice and device.controller.js etc.
You get the point.
So which means I am wasting a lot of time on somethings that I could automate, time which I could easily focus on optimizing the code and making it bug-free.
So I wanted to have two birds in one shot. And thus born my first npm package and my lazy file structuring habit (although it's quite nice and powerful).
The package can be obtained from, of course, npm.
Here's the link do try it out.
https://www.npmjs.com/package/lnfc
Now I know the name is quite vague. But hold on to me, I am in the process of making it better.
What the package does, once you install it globally is create a file/folder structure within your barebones projects, with only a few keystrokes, so that you can forget about your nitty bitty code and focus only on your code logic.
C'mon ask yourself how many hours do you waste in your life, writing that same set of code structure but only with a name change?
It gave me immense joy to share it with you here.
But it's not something I was planning to do. Things happen you know.
Quickly and unexpectedly.
I was working on a MEAN stack project for the last 2-3 months. When working on the backed of stuff, I was going on creating files and doing the same or somewhat same set of codes over and over again.
If it's something related to user, then the file name of the controller is user.controller.js and the service file name is user.service.js. With method, names are getUser, or getUsers, or deleteUser.
And if it's on some other stuff, say a device, most of the logic remains the same, except this time the name of the method and files changes to deleteDevice and device.controller.js etc.
You get the point.
So which means I am wasting a lot of time on somethings that I could automate, time which I could easily focus on optimizing the code and making it bug-free.
So I wanted to have two birds in one shot. And thus born my first npm package and my lazy file structuring habit (although it's quite nice and powerful).
The package can be obtained from, of course, npm.
Here's the link do try it out.
https://www.npmjs.com/package/lnfc
Now I know the name is quite vague. But hold on to me, I am in the process of making it better.
What the package does, once you install it globally is create a file/folder structure within your barebones projects, with only a few keystrokes, so that you can forget about your nitty bitty code and focus only on your code logic.
C'mon ask yourself how many hours do you waste in your life, writing that same set of code structure but only with a name change?
Comments
Post a Comment