Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Generated routes do not retain the port number #374

Closed
they-cloned-me opened this issue Nov 21, 2020 · 2 comments · Fixed by #386
Closed

Generated routes do not retain the port number #374

they-cloned-me opened this issue Nov 21, 2020 · 2 comments · Fixed by #386
Assignees
Labels

Comments

@they-cloned-me
Copy link

Description

I'm using Ziggy with on a Laravel/Vue project. I installed and configured ziggy as per the documentation, .i.e

@routes
<script src="{{ mix('/js/app.js') }}" defer></script>

My app.js looks like:

import { createApp, h } from 'vue'
 
const app = createApp({
  // ...
})

app.mixin({
  methods: { route: window.route }
})

Every looks good, except my routes are missing the port number.
instead of: localhost:8000/home,
I have: localhost/home

How can I configure it to add the port number (when I'm using on my local machine)?
Thanks

Environment

  • Laravel: ^8.12
  • Ziggy: ^1.0
  • Vuejs: 3
  • Windows 10 Pro
@bakerkretzmar
Copy link
Collaborator

bakerkretzmar commented Nov 21, 2020

@fsavalam for now as a quick fix, it should work if you add :8000 to your APP_URL environment variable.

It seems like #334 may have broken automatic support for ports... I'll look into that.

@bakerkretzmar bakerkretzmar self-assigned this Nov 21, 2020
@they-cloned-me
Copy link
Author

Thanks

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants