ohseesoftware / laravel-vite-manifest

A simple Laravel package to include Vite's compiled assets from the generated manifest file.
MIT License
8 stars 6 forks source link

Odd Behavior with Directive String #1

Closed iancallahan closed 3 years ago

iancallahan commented 3 years ago

Hello! Thanks for this package. This is more of a head's up for anyone else who may be experiencing this.

I have an odd set up where I'm wedging an SPA into an existing website. So my entry file is 'index.html'.

Here's the odd thing. If I use: @vite('index.html')

I get an error: syntax error, unexpected 'index' (T_STRING), expecting ')'

If I use double quotes, the string gets passed but it includes the quotes as html entities: "index.html"

But the following, without quotes, works like a charm: @vite(index.html)

It's probably some peculiar thing about MacOS as I've encountered this issue running locally using Valet.

Thanks again.

owenconti commented 3 years ago

@iancallahan My blade directive is including the quotes automatically, so I think the README is incorrect