Rulqu opened a new issue, #2018:
URL: https://github.com/apache/jena/issues/2018

   ### Version
   
   4.9.0
   
   ### Feature
   
   Add env for vite to build the files with a path. For example I'd like to be 
able to build the webui like this:
   `VITE_PUBLIC_PATH=/fuseki/ yarn build` and then it can be hosted under 
/fuseki/ path.
   
   I've fixed this myself for my needs but I don't know if this is good enough 
for a pull request.
   ```
   diff --git a/jena-fuseki2/jena-fuseki-ui/vite.config.js 
b/jena-fuseki2/jena-fuseki-ui/vite.config.js
   index 612de16ad8..07ed9db898 100644
   --- a/jena-fuseki2/jena-fuseki-ui/vite.config.js
   +++ b/jena-fuseki2/jena-fuseki-ui/vite.config.js
   @@ -15,13 +15,16 @@
     * limitations under the License.
     */
    
   -import { defineConfig } from 'vite'
   +import { defineConfig, loadEnv } from 'vite'
    import vue from '@vitejs/plugin-vue'
    import istanbul from "vite-plugin-istanbul";
    const path = require("path")
    
    // https://vitejs.dev/config/
   -export default defineConfig({
   +export default defineConfig(({ command, mode }) => {
   +  const env = loadEnv(mode, process.cwd(), '')
   +  return {
   +    base: env.VITE_PUBLIC_PATH || '/',
        plugins: [
          vue(),
          istanbul({
   @@ -116,4 +119,5 @@ export default defineConfig({
            }
          },
        }
   +  }
    })
   ```
   
   ### Are you interested in contributing a solution yourself?
   
   Yes


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to