Update threejs server

This commit is contained in:
Alexander Nozik 2023-01-17 19:20:48 +03:00
parent 2bdaea2e82
commit 35fc7a7042
5 changed files with 45 additions and 6 deletions

View File

@ -12,7 +12,7 @@ val fxVersion by extra("11")
allprojects {
group = "space.kscience"
version = "0.3.0-dev-5"
version = "0.3.0-dev-7"
}
subprojects {

View File

@ -10,6 +10,11 @@ kotlin {
webpackTask {
this.outputFileName = "js/visionforge-three.js"
}
commonWebpackConfig {
cssSupport{
enabled.set(false)
}
}
}
binaries.executable()
}
@ -17,17 +22,18 @@ kotlin {
sourceSets {
commonMain {
dependencies {
api(project(":visionforge-solid"))
api(projects.visionforgeSolid)
}
}
jvmMain {
dependencies {
api(project(":visionforge-server"))
api(projects.visionforgeServer)
}
}
jsMain {
dependencies {
api(project(":visionforge-threejs"))
api(projects.visionforgeThreejs)
api(projects.ui.ring)
}
}
}

View File

@ -1,11 +1,11 @@
package space.kscience.visionforge.three
import space.kscience.dataforge.misc.DFExperimental
import space.kscience.visionforge.ring.ThreeWithControlsPlugin
import space.kscience.visionforge.runVisionClient
import space.kscience.visionforge.solid.three.ThreePlugin
@DFExperimental
public fun main(): Unit = runVisionClient {
plugin(ThreePlugin)
plugin(ThreeWithControlsPlugin)
}

View File

@ -0,0 +1,23 @@
const ringConfig = require('@jetbrains/ring-ui/webpack.config').config;
const path = require('path');
config.module.rules.push(...ringConfig.module.rules)
config.module.rules.push(
{
test: /\.css$/,
exclude: [
path.resolve(__dirname, "../../node_modules/@jetbrains/ring-ui")
],
use: [
{
loader: 'style-loader',
options: {}
},
{
loader: 'css-loader',
options: {}
}
]
}
)

View File

@ -0,0 +1,10 @@
const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
module.exports = {
plugins: [
new BundleAnalyzerPlugin({
analyzerMode: "static",
reportFilename: "bundle-report.html"
})
]
}