Parser for JavaScript

A place to discuss the development of Regnus parsers for different platforms or languages.
Post Reply
veryalien
Posts: 13
Joined: Wed Apr 16, 2014 am30 9:13 am

Parser for JavaScript

Post by veryalien » Sun Apr 20, 2014 pm30 2:06 pm

Isn't there some use for a client-side parser running locally directly in the user's browser?

This would be a variation of the server-side PHP parser. but Instead of reading a rsf file from the local filesystem, a script could be 'loaded' by using an array containing each line of the Regnus script to be processed.

The Regnus parser JavaScript could then be referenced or embedded in each page as needed and the rsf array could be passed as a parameter to Regnus. The result could simply be returned as a text string to the rest of the JavaScript on the page.

Referencing other scripts in other local files, without using a web server, wouldn't work. But concatenating all the relevant scripts into one array would avoid that issue.

Neil

User avatar
Ryan
Site Admin
Posts: 142
Joined: Wed Nov 11, 2009 pm30 8:19 pm
Contact:

Re: Parser for JavaScript

Post by Ryan » Tue Apr 22, 2014 pm30 3:54 pm

A JS Regnus parser would certainly be a cool idea - especially as it would essentially be platform independent. Combined with a browser-based text editor, it could function as a complete online Regnus scripting environment. :)

Ryan

Post Reply