Closed siba2893 closed 2 years ago
Hi Daniel, please share a repo with a minimal reproduction and I'll take a look.
I tested in an app, and it generated confirmations as well:
// JsFromRoutes CacheKey d373e19a0694ae472b5b76beaad73f93
//
// DO NOT MODIFY: This file was automatically generated by JsFromRoutes.
import { definePathHelper } from '~/services/api'
export default {
new: definePathHelper('get', '/users/confirmation/new'),
show: definePathHelper('get', '/users/confirmation'),
create: definePathHelper('post', '/users/confirmation'),
}
Yes of course here is the example project I was making https://github.com/siba2893/inertia_example_rails_7
If you run bin/rails routes | grep confirmations
in the app, you will notice there are no routes for confirmations
, which is the reason why js_from_routes
is not generating helpers.
The reason Devise is not adding those routes is related to the Devise configuration, you must add :confirmable
to the User
model.
OMG thank you so much for finding the out.
bundle update js_from_routes
.Description 📖
Hey I was trying for the Rails + Vite + Vue 3 + Inertia.js combo, while comparing the Original Demo App vs your version of the Demo App, I love the gem that you built called
js_from_routes
its quite cool.But I encounter a problem, for some reason the gem doesn't want to generate the
users/confirmations_controller
routes for Devise, it does generate thesessions, registrations, passwords
but not the confirmations.You can see at the screenshot how all the other controllers are there as Api routes.
Reproduction/Logs 🐞📜
Add the confirmations_controller in your devise example app and try to see if it generates the routes.
Screenshots 📷