Created
January 24, 2017 13:06
-
-
Save ichiriac/6756053e780f94da9647d4279557daad to your computer and use it in GitHub Desktop.
Quick Start / Usage / php-transpiler
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// initialize the php parser factory class | |
var engine = require('php-parser'); | |
var transpiler = require('php-transpiler'); | |
var jsCode = transpiler.generate( | |
engine.parseCode('<?php echo "Hello World";') | |
); | |
console.log(jsCode); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment