CCM NG: Working integration of NPM modules
git-svn-id: https://svn.libreccm.org/ccm/ccm_ng@5462 8810af33-2d31-482b-a856-94f89814c4df
parent
81d1c9bdd7
commit
b34a056775
File diff suppressed because it is too large
Load Diff
|
|
@ -0,0 +1,17 @@
|
||||||
|
{
|
||||||
|
"name": "ccm-bundle-devel",
|
||||||
|
"version": "7.0.0",
|
||||||
|
"scripts": {
|
||||||
|
"build": "webpack"
|
||||||
|
},
|
||||||
|
"dependencies": {
|
||||||
|
"ccm-cms-js": "7.0.0"
|
||||||
|
},
|
||||||
|
"devDependencies": {
|
||||||
|
"ts-loader": "^4.3.0",
|
||||||
|
"tslint": "^5.10.0",
|
||||||
|
"typescript": "^2.8.3",
|
||||||
|
"webpack": "^4.8.1",
|
||||||
|
"webpack-cli": "^2.1.3"
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -38,11 +38,25 @@
|
||||||
<artifactId>requirejs-domready</artifactId>
|
<artifactId>requirejs-domready</artifactId>
|
||||||
<version>2.0.1-2</version>
|
<version>2.0.1-2</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.librecms</groupId>
|
||||||
|
<artifactId>ccm-cms-js</artifactId>
|
||||||
|
<version>7.0.0-SNAPSHOT</version>
|
||||||
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
<build>
|
<build>
|
||||||
<finalName>libreccm-web-wildfly</finalName>
|
<finalName>libreccm-web-wildfly</finalName>
|
||||||
|
|
||||||
|
<resources>
|
||||||
|
<resource>
|
||||||
|
<directory>src/main/resources</directory>
|
||||||
|
</resource>
|
||||||
|
<resource>
|
||||||
|
<directory>${project.build.directory}/generated-resources</directory>
|
||||||
|
</resource>
|
||||||
|
</resources>
|
||||||
|
|
||||||
<plugins>
|
<plugins>
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
|
@ -56,10 +70,74 @@
|
||||||
</configuration>
|
</configuration>
|
||||||
</plugin>
|
</plugin>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<groupId>com.github.eirslett</groupId>
|
||||||
|
<artifactId>frontend-maven-plugin</artifactId>
|
||||||
|
|
||||||
|
<configuration>
|
||||||
|
<installDirectory>../node</installDirectory>
|
||||||
|
</configuration>
|
||||||
|
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>Install node.js and NPM</id>
|
||||||
|
<goals>
|
||||||
|
<goal>install-node-and-npm</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<nodeVersion>v8.11.1</nodeVersion>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
<!--<execution>
|
||||||
|
<id>npm link ccm-pagemodelseditor</id>
|
||||||
|
<goals>
|
||||||
|
<goal>npm</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<arguments>link ccm-pagemodelseditor</arguments>
|
||||||
|
</configuration>
|
||||||
|
</execution>-->
|
||||||
|
<execution>
|
||||||
|
<id>npm link ccm-cms-js</id>
|
||||||
|
<goals>
|
||||||
|
<goal>npm</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<arguments>link ccm-cms-js</arguments>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
<execution>
|
||||||
|
<id>npm install</id>
|
||||||
|
<goals>
|
||||||
|
<goal>npm</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
<execution>
|
||||||
|
<id>build</id>
|
||||||
|
<goals>
|
||||||
|
<goal>npm</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<arguments>run build</arguments>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
<artifactId>maven-war-plugin</artifactId>
|
<artifactId>maven-war-plugin</artifactId>
|
||||||
<configuration>
|
<configuration>
|
||||||
|
|
||||||
|
<webResources>
|
||||||
|
<resource>
|
||||||
|
<directory>src/main/resources</directory>
|
||||||
|
</resource>
|
||||||
|
<resource>
|
||||||
|
<directory>${project.build.directory}/generated-resources</directory>
|
||||||
|
</resource>
|
||||||
|
</webResources>
|
||||||
|
|
||||||
<overlays>
|
<overlays>
|
||||||
<overlay>
|
<overlay>
|
||||||
<groupId>org.libreccm</groupId>
|
<groupId>org.libreccm</groupId>
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1 @@
|
||||||
|
import "ccm-cms-js";
|
||||||
|
|
@ -0,0 +1,13 @@
|
||||||
|
{
|
||||||
|
"compilerOptions": {
|
||||||
|
"module": "commonjs",
|
||||||
|
"moduleResolution": "node",
|
||||||
|
"sourceMap": true,
|
||||||
|
"strict": true,
|
||||||
|
"target": "es6",
|
||||||
|
},
|
||||||
|
"include": [
|
||||||
|
"src/main/typescript/*"
|
||||||
|
]
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,19 @@
|
||||||
|
{
|
||||||
|
"defaultSeverity": "error",
|
||||||
|
"extends": [
|
||||||
|
"tslint:recommended"
|
||||||
|
],
|
||||||
|
"jsRules": {},
|
||||||
|
"rules": {
|
||||||
|
"interface-name": {
|
||||||
|
"options": ["never-prefix"]
|
||||||
|
},
|
||||||
|
"max-classes-per-file": {
|
||||||
|
"options": [100]
|
||||||
|
},
|
||||||
|
"max-line-length": {
|
||||||
|
"options": [80]
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"rulesDirectory": []
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,28 @@
|
||||||
|
const path = require('path');
|
||||||
|
|
||||||
|
module.exports = {
|
||||||
|
|
||||||
|
devtool: "source-map",
|
||||||
|
|
||||||
|
entry: {
|
||||||
|
ccmcms: "./src/main/typescript/ccm-cms.ts"
|
||||||
|
},
|
||||||
|
|
||||||
|
mode: "production",
|
||||||
|
|
||||||
|
output: {
|
||||||
|
//path: path.resolve(__dirname, "src/main/resources/dist"),
|
||||||
|
path: path.resolve(__dirname, "target/generated-resources/scripts/dist"),
|
||||||
|
filename: "ccm-cms.js"
|
||||||
|
},
|
||||||
|
|
||||||
|
resolve: {
|
||||||
|
extensions: [".webpack.js", "web.js", ".ts", ".tsx", ".js"]
|
||||||
|
},
|
||||||
|
|
||||||
|
module: {
|
||||||
|
rules: [
|
||||||
|
{ test: /\.tsx?$/, loader: "ts-loader"}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
@ -57,23 +57,8 @@
|
||||||
|
|
||||||
<plugins>
|
<plugins>
|
||||||
|
|
||||||
<!-- <plugin>
|
<!-- <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-remote-resources-plugin</artifactId> <version>1.5</version> <configuration> <resourceBundles>
|
||||||
<groupId>org.apache.maven.plugins</groupId>
|
<resourceBundle>org.libreccm:ccm-pagemodelseditor:${project.version}</resourceBundle> </resourceBundles> </configuration> <executions> <execution> <goals> <goal>process</goal> </goals> </execution> </executions> </plugin> -->
|
||||||
<artifactId>maven-remote-resources-plugin</artifactId>
|
|
||||||
<version>1.5</version>
|
|
||||||
<configuration>
|
|
||||||
<resourceBundles>
|
|
||||||
<resourceBundle>org.libreccm:ccm-pagemodelseditor:${project.version}</resourceBundle>
|
|
||||||
</resourceBundles>
|
|
||||||
</configuration>
|
|
||||||
<executions>
|
|
||||||
<execution>
|
|
||||||
<goals>
|
|
||||||
<goal>process</goal>
|
|
||||||
</goals>
|
|
||||||
</execution>
|
|
||||||
</executions>
|
|
||||||
</plugin> -->
|
|
||||||
|
|
||||||
<plugin>
|
<plugin>
|
||||||
<groupId>com.github.eirslett</groupId>
|
<groupId>com.github.eirslett</groupId>
|
||||||
|
|
@ -117,6 +102,15 @@
|
||||||
<arguments>run build</arguments>
|
<arguments>run build</arguments>
|
||||||
</configuration>
|
</configuration>
|
||||||
</execution>
|
</execution>
|
||||||
|
<execution>
|
||||||
|
<id>npm link</id>
|
||||||
|
<goals>
|
||||||
|
<goal>npm</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<arguments>link</arguments>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
</executions>
|
</executions>
|
||||||
</plugin>
|
</plugin>
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue