Skip to content

support ramda expression #232

@naratteu

Description

@naratteu
#r "nuget: Jurassic, 3.2.9"
var engine = new Jurassic.ScriptEngine();
engine.SetGlobalValue("console", new Jurassic.Library.FirebugConsole(engine));
engine.Execute("""
const ramda = (a, b) => a + b;
console.log(ramda(3,4)); // 7
""");
Error: Jurassic.JavaScriptException: SyntaxError: Unexpected token '>' in expression.
at Jurassic.ScriptEngine.Execute(ScriptSource source)
at Jurassic.ScriptEngine.Execute(String code)
at Submission#31.<<Initialize>>d__0.MoveNext()
--- End of stack trace from previous location ---
at Microsoft.CodeAnalysis.Scripting.ScriptExecutionState.RunSubmissionsAsync[TResult](ImmutableArray`1 precedingExecutors, Func`2 currentExecutor, StrongBox`1 exceptionHolderOpt, Func`2 catchExceptionOpt, CancellationToken cancellationToken)

Also, it would be nice if the line with the error was also printed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions