HMR and Hot hooks Issue -- Code is not updated #4552
-
Hi, I was testing the new HMR and Hoot hooks feature. below are my settings.
if i make changes to controller file, it works. vite does not refresh page and i get the updated code on next request. but the issue is if i make changes to services file which is injected as dependency in controller, vite still doesn't refresh the page that is good but the outdated code on executed on next request. i have to full reload server to get the updated code. not only with services file, but all the files except controller, like ploicies , validators etc. but this was not the case with hothook v0.2.0. this is happening when i upgraded to v0.2.2. and now i also tried 0.2.4 its same. |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 6 replies
-
Why adding If the problem persists after removing them, then a reproduction would be desirable please. Otherwise it will be hard to help you |
Beta Was this translation helpful? Give feedback.
-
I have the same issue, I'm experimenting AdonisJs v6 with inertia adapter, I have a simple controller import User from '#models/user'
import type { HttpContext } from '@adonisjs/core/http'
export default class AboutController {
async handle({ inertia }: HttpContext) {
const users = await User.all()
return inertia.render('about', { users: users, ok: 'test' })
}
} I'm running hmr with
but the changes in package.json for reference
not sure where the issue was. |
Beta Was this translation helpful? Give feedback.
Why adding
"./database/**/*.ts"
and"./resources/*.ts"
as boundaries? It's probably not what you wantIf the problem persists after removing them, then a reproduction would be desirable please. Otherwise it will be hard to help you