0๐
Do a npm install first on taffy npm install --production taffy
then after that go to the code you want to use it on and require it TAFFY = require( 'taffy' ).taffy;
in the documentation it says require it try it that way instead of doing import from.
Check the documents to https://www.npmjs.com/package/taffydb#use-it-in-nodejs
I hope this helps you out !
- [Vuejs]-Vue v-model does not seem to be working in modal
- [Vuejs]-Show a default placeholder in a select VueJS
0๐
I have the same problem. I will resolve doing this:
-
Download taffy-min.js on official page
-
Move this file to /plugin folder on your project
-
In the file .vue that you need use. Copy this line on script section
import { taffy } from โ@/plugins/taffy-min.jsโ;
-
And on mounted()methods you can write:
const friends = taffy([ {"id":1,"gender":"M","first":"John","last":"Smith","city":"Seattle, WA","status":"Active"}, {"id":2,"gender":"F","first":"Kelly","last":"Ruth","city":"Dallas, TX","status":"Active"},
{"id":3,"gender":"M","first":"Jeff","last":"Stevenson","city":"Washington, D.C.","status":"Active"},
{"id":4,"gender":"F","first":"Jennifer","last":"Gill","city":"Seattle, WA","status":"Active"}
]);
More: if you are using Typerscript, dont forget write "declare module โ@/plugins/taffy-min.jsโ;" on "delcarations.d.ts" on src folder to work.
I hope work for you! Sorry for my english! ๐