2.0.2 • Published 1 year ago

js2cp v2.0.2

Weekly downloads
-
License
MIT
Repository
github
Last release
1 year ago

JS2CP

A Javascript to C++ "Translator", built from Node.js!

Installation

Local install

npm install js2cp

Usage

Local usage

const js2cp = require("js2cp")
js2cp.translate("Path to js program") //js2cp.translate("test.js")

Examples


Let's assume u have your extra powerful hello world program.

helloWorld.js

With insane "Hello World!" code inside

console.log("Hello World!")

How to translate

    const js2cp = require("js2cp")
    js2cp.translate("./helloWorld.js")

This will create a new file.In our case helloWorld.cpp

./helloWorld.cpp

#include <iostream>

int main(){

std::cout <<"Hello World!"<< std::endl;

// If you want to pause the program at the end just uncomment line below
// system("pause>0")
};

Info

Translator does not support the "frontend technologies", like document.querySelector etc. So please, don't even try it, it will compile with bugs.

JS2CP is build for "competetive programming" applications. That means, with logic of complexity in js functions.

JS2CP is still under development, so use it wisely.

PSS: If you have any questions or complaints, please open issue on the GitHub https://github.com/borecjeborec1/

2.0.2

1 year ago

2.0.1

1 year ago

2.0.0

1 year ago

1.0.12

3 years ago

1.0.9

3 years ago

1.0.8

3 years ago

1.0.7

3 years ago

1.0.6

3 years ago

1.0.5

3 years ago

1.0.4

3 years ago

1.0.11

3 years ago

1.0.10

3 years ago

1.0.2

3 years ago

1.0.3

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago