Can I share a properties file between java and javascript? -
i need have access properties file within java web application. put in classpath somewhere, , load using getresourceasstream("my.properties")
.
i need access same properties file within javascript. know read using xhr if file exists in web resources folder, in case not.
what can here? i'm trying avoid 2 copies of file.
project - javasource - myclass.java - my.properties - webcontent - myjavascript.js
you can write java service turns properties file json. it's pretty easy do, , i've done in few projects. can call ajax or referencing in script tag.
Comments
Post a Comment