RobinCK / typeorm-fixtures

:pill: Fixtures loader for typeorm 🇺🇦
https://robinck.github.io/typeorm-fixtures/
MIT License
566 stars 45 forks source link

fix: Recognize EJS over multiple lines #162

Closed poldridge closed 3 years ago

poldridge commented 3 years ago

The s flag allows . to match newlines so that if the value only contains a multiline EJS expression it will still be rendered by EJS. It allows this to work:

    status: >-
      <%= 
        [ 
          'pending_approval',
          'approved',
          'rejected',
        ][ ~~(Math.random()*3) ]
      %>
RobinCK commented 3 years ago

thanks