Comments (2)
Calling
route('invalid.route')
should definitely error and you should see it in the browser console. Is that exactly the code in your app? What page is it on in the Inertia template? Do you have anything like Sentry set up that might be swallowing errors? Are you having this issue in development mode or with a full Vite build, or both?Making
route()
stricter about the route names passed into it is something I'm totally open to.
Oof, I was either extremely inattentive or it for some reason didn't show up in the browser console at the time I checked. It does indeed show up in the browser console now that I check again. Sorry for misinforming on that part.
Question, is it possible to have it check all the route
calls at build-time? If not, then either way, I guess the simplest solution would be to provide an option to show the error in development time: optional Typescript error/warning.
If this solution is chosen, then the next natural question would be - where to put the option? In what configuration file? If I am not mistaken, the ziggy.js file is not made for that. I guess it'd be put as into some kind of an options
param while calling app.use(ZiggyVue({strictRoutes: true}))
, making ZiggyVue callable, right?
from ziggy.
Calling route('invalid.route')
should definitely error and you should see it in the browser console. Is that exactly the code in your app? What page is it on in the Inertia template? Do you have anything like Sentry set up that might be swallowing errors? Are you having this issue in development mode or with a full Vite build, or both?
Making route()
stricter about the route names passed into it is something I'm totally open to.
from ziggy.
Related Issues (20)
- False negative with route().current() and nested params
- Using `route()->current('...*')` multiple time issue
- Arrow function given to Event::listen stops further propagating of the event HOT 2
- Vue Plugin isnt delivered with Composer package
- Laravel 11 support HOT 2
- Class "Tightenco\Ziggy\Ziggy" Not Found After Upgrading to Laravel 11 HOT 2
- This package does not work with Folio named routes HOT 1
- Passing Ziggy configuration to Inertia.js SSR in a Svelte app
- TypeError when optional params omitted from array
- package does not handle a Vue 2 codebase well HOT 1
- Vue: Cannot convert undefined or null to object
- Feature: Add ```route().queryParams``` to get only query params without laravel route params
- Export Helper type to get the parameters type of specific route
- Missing alert or Logic problem on current route method
- Ziggy generates URL with a double leading slash HOT 6
- Error message : Ziggy is not defined
- "Resolving Infinite Loop Issues in resolveBindings Function"
- Ziggy generating wrong params for resources with param url HOT 5
- Ziggy route() helper TypeError: Cannot read properties of undefined (reading 'home.index') HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ziggy.