Giter VIP home page Giter VIP logo

unvell / reoscript Goto Github PK

View Code? Open in Web Editor NEW
104.0 11.0 35.0 3.16 MB

JavaScript-like script language engine for .NET Application. Easy to plug in .NET Application and making API extension for script. Enhanced syntax and features are also available such as lambda expression, call setTimeout with arguments, etc...

Home Page: https://github.com/unvell/ReoScript/wiki

C# 99.95% Batchfile 0.05%
script script-language ecmascript javascript interpreter integration script-integration lambda-expressions script-executor inapp-script

reoscript's Introduction

ReoScript

ReoScript is an ECMAScript-like script language interpreter designed to integrate in .NET program. ReoScript makes your application can run script program.

Features

  • ECMAScript-like syntax
  • Various methods support to integrate into .NET application
  • Support to add customize objects, types and functions
  • Directly access to .NET classes; including using .NET framework classes
  • Enhanced syntax and extension features, like import keyword and lambda expressions

License

MIT License

Copyright (c) unvell inc., Jingwood 2012-2022, all rights reserved.

reoscript's People

Contributors

jingwood avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

reoscript's Issues

Variables declared in outer function can not be cached (v1.2)

Variables declared in outer function but used in inner function can not be cached so the following code does not work in ReoScript.

fun1 = function() { 
  var cached_var = 10;

  return function() {
    console.log('cached_var = ' + cached_var);
  };
} ();

fun1();

The result is that cached_var is null.

.net dynamic objects

I just found your fantastic library today. It seems to perform well and was easy to get setup.

In my application, I am passing some global variables to the script machine that are dynamic objects in.net.

It seems like they are coming in as null.

Am I correct in assuming there is no support for .net dynamic objects at this time?

Best,
Brad Murry

Consider using a different file extension

.rs is used by Rust; it'd be convenient if the file extension for ReoScript were changed to something else. A quick search suggests that .reo is unused, it sounds to me a better (more discoverable) extension for ReoScript, too.

Compiling a script does not display errors

I just found ReoScript and have been playing around with it in VS 2010 (C#) and trying to decide if I want to use it in an email processor I am writing.

One thing I am noticing is that ReoScript does not seam to parse the script until it actual it runs, meaning the srm.compile does not throw any errors if they are errors in the script. It also does not collect all the variables used in the script until it is ran.

What is the point of compiling? I want to be able to to tell my users that there script has error before actually running the script.

Thanks for a nice LIB!
-=Ryan

Inner function should be pre-interpreted in all of call-scopes (v1.2)

Curernt ReoScript does not pre-interpret the inner functions which defined inside another function scope. Function call before its definition currently is not available.

function outer() {
  inner();           // error: Function is not defined: inner

  function inner() {
    console.log('inner called');
  };
};

outer();

This issue is planned to be solved in next release.

Error in Chinese

 helper.StartScript("table(1).cell(1,2).text=\"1112\";"); // is ok
 helper.StartScript("表格(1).单元格(1,2).文本=\"1112\";");// is error

    public void StartScript(string js)
    {
        CompiledScript cs = null;
        try {
            cs = script.Compile(js);              // string end without '
            script.RunCompiledScript(cs);

        } catch (ReoScriptCompilingException ex) {
            MessageBox.Show(ex.Message, "error", MessageBoxButtons.OK, MessageBoxIcon.Error);
        }
    }

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.