-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
added fastify server support #11
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@SerVitasik great speed 💪, let's move common html snippet to file genericServer.ts both express server and fastify should extend the class from this file
@@ -101,7 +59,7 @@ class ExpressServer implements IExpressHttpServer { | |||
await proxyTo(`http://localhost:5173${req.url}`, res); | |||
} catch (e) { | |||
// console.log('Failed to proxy', e); | |||
res.status(500).send(respondNoServer('AdminForth SPA is not ready yet', 'Vite is still starting up. Please wait a moment...')); | |||
res.status(500).send(this.respondNoServer('AdminForth SPA is not ready yet', 'Vite is still starting up. Please wait a moment...')); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@SerVitasik I think the string literals should be moved as well.
@@ -134,7 +92,7 @@ class ExpressServer implements IExpressHttpServer { | |||
fileExists = false; | |||
} | |||
if (!fileExists) { | |||
res.status(500).send(respondNoServer(`${this.adminforth.config.customization.brandName} is still warming up`, 'Please wait a moment...')); | |||
res.status(500).send(this.respondNoServer(`${this.adminforth.config.customization.brandName} is still warming up`, 'Please wait a moment...')); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same
No description provided.