Closed zzhenryquezz closed 2 years ago
Because the dashboard is a project separated of you-space it will need a bridge between they.
It will work as the themes, it will get a filename and then return the string. Ex:
async function render({ url, response }) { if (url === '/') { return fs.promises.readFile(path.resolve(__dirname, 'dist', 'index.html')) } if (url === '/main.js') { return fs.promises.readFile(path.resolve(__dirname, 'dist', 'main.,js')) } }
In you-space
import Route from '@ioc:Adonis/Core/Route' import Dashboard from '@you-space/dashboard' Route.get('/ys-admin/*', Dashboard.render)
ys-admin
Because the dashboard is a project separated of you-space it will need a bridge between they.
It will work as the themes, it will get a filename and then return the string. Ex:
In you-space
Outcome
ys-admin