Skip to content

Package goja-parse is a JavaScript parser written natively in Go.

Notifications You must be signed in to change notification settings

zbysir/goja-parser

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

goja-parser

Package goja-parse is a JavaScript parser written natively in Go.

This project was largely inspired by goja

Unlike Goja, this package only has the parse function, because I added some es6 features for parser, but it is too complicated for me to interpret it;

Added syntax

  • Spread syntax
    • For function calls:
      myFunction(...iterableObj); // pass all elements of iterableObj as arguments to function myFunction
      
    • For array literals or strings:
      [...iterableObj, '4', 'five', 6]; // combine two arrays by inserting all elements from iterableObj
      
    • For object literals (new in ECMAScript 2018):
      let objClone = { ...obj }; // pass all key:value pairs from an object 
      

About

Package goja-parse is a JavaScript parser written natively in Go.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published