Skip to content

Question: passing code via pipe? #520

@amilajack

Description

@amilajack

I'm using the following code to pass javascript source code (as a string) as stdout to anther command.

exec(`echo "${jsCodeHere}" | someOtherCommand`)

The issue with this is there are a bunch of issues caused by the syntax of javascript being evaluated by bash. Is there a better way of doing this?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions