Closed waqas-mehmood-pk closed 6 years ago
This is the standard node fs module: https://nodejs.org/api/fs.html#fs_file_system
@whfamily2006 Can you post the error you are getting?
$ node
> require('ifsc').validate('HDFC0000001')
true
Error on my side:
ERROR Failed to compile with 1 errors11:56:49 AM
This dependency was not found:
* fs in ./~/ifsc/src/node/index.js
To install it, you can run: npm install --save fs
But I have installed fs npm package, here is my package.json dependencies:
"dependencies": {
"babel-plugin-transform-runtime": "^6.23.0",
"chart.js": "^2.7.1",
"datatables.net": "^1.10.16",
"datatables.net-dt": "^1.10.16",
"fs": "0.0.1-security",
"ifsc": "^1.0.11",
"select2": "^4.0.5",
"vue-chartjs": "^2.8.7",
"vue-good-table": "^1.16.0",
"vue-search-select": "^2.4.0",
"vue-strap": "^1.1.40",
"vue-template-compiler": "^2.5.7",
"vuejs-datepicker": "git+https://github.com/paaysay/vuejs-datepicker.git"
}
Please remove the fs package from your npm setup and try again. The fs
module is part of node and is not required to be installed.
The package seems to be all fine: https://runkit.com/embed/hyy84qcdmjkl
Thanks @captn3m0
Even I install fs
package or remove from my package.json, in both cases error occurred.
Are you using it with webpack? This package works with node.
Yes, I am using this with webpack, is it possible or not with webpack?
This is a Node.JS only package as of now, since the package does offline validation over a 300kb file, which you don't want to load over a web browser.
Instead, just make a AJAX request to https://ifsc.razorpay.com/{IFSC}
to validate a IFSC code for a much faster method.
Same Error not able to find fs module even i have installed it globally on my system. Kindly assist waiting for your reply.
inside the npm package
src/node/index.js
file very first line requires thefs
npm package butfs
package not exists. can you please tell me about thisrequire('fs')
.