0

I have a task - parsing data of this type ("Query1" OR "Query2") AND ("Quesy3" OR "Query4")

I am using TsPeg for this. Everything worked out, but how can you use the parse() method of library inside a Vue project?

Simply put, I need to pull out a method available in Node.js in VueJS

Harvey
  • 172
  • 1
  • 7
  • 2
    ? `import {} from ""` - the limit nodejs might be an issue if you need access to more than just v8 in the browser – Estradiaz Sep 25 '20 at 07:13

1 Answers1

1

You can put parser as ~/modules/parser.js where ~/ is root dir for vue. Then you can simply import and use in your vue file's <script></script> tag

import { sum } from '~/modules/parser.js' 
Swapnil Soni
  • 965
  • 1
  • 10
  • 26