aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Config.md52
-rw-r--r--README.md16
2 files changed, 23 insertions, 45 deletions
diff --git a/Config.md b/Config.md
index 3bb2198c..83cd27ef 100644
--- a/Config.md
+++ b/Config.md
@@ -18,58 +18,22 @@ Next add dependencies on Kotlin and KVision:
}
KVision applications are using [Kotlin frontend plugin](https://github.com/Kotlin/kotlin-frontend-plugin)
-to download and integrate a number of NPM dependencies. To make upgrades easier, all of them are listed in
-the single **npm.dependencies** file, located in the root directory of the project.
+to download and integrate a number of NPM dependencies. Some of them are listed in
+a separate **npm.dependencies** file, located in the root directory of the project.
Currently this file contains:
- css-loader *
- style-loader *
- less *
- less-loader *
- imports-loader *
- uglifyjs-webpack-plugin *
- file-loader *
- url-loader *
- jquery 3.3.1
bootstrap 3.3.7
bootstrap-webpack 0.0.6
- font-awesome 4.7.0
- font-awesome-webpack 0.0.5-beta.2
- awesome-bootstrap-checkbox 0.3.7
bootstrap-select 1.12.4
ajax-bootstrap-select 1.4.3
- trix 0.11.1
- fecha 2.3.2
bootstrap-datetime-picker 2.4.4
bootstrap-touchspin 3.1.1
- snabbdom 0.6.9
- snabbdom-virtualize 0.7.0
- navigo 7.0.0
- jquery-resizable-dom 0.26.0
-
-In case of an upgrade you should synchronize above content with the same [file](https://raw.githubusercontent.com/rjaros/kvision/master/npm.dependencies)
-located in the KVision source tree on GitHub.
-
-NPM dependencies are used in your build.gradle with the following configuration:
+ font-awesome 4.7.0
+ font-awesome-webpack 0.0.5-beta.2
+ awesome-bootstrap-checkbox 0.3.7
+ trix 0.11.1
- buildscript {
- ...
- ext.npmdeps = new File("npm.dependencies").getText()
- ...
- }
- ...
- kotlinFrontend {
- npm {
- npmdeps.eachLine { line ->
- def (name, version) = line.tokenize(" ")
- dependency(name, version)
- }
- devDependency("karma")
- }
- webpackBundle {
- bundleName = "main"
- contentPath = file('src/main/web')
- }
- }
+These are optional dependencies and can be removed if the corresponding features are not used in your KVision application.
+This can make the generated JavaScript code much smaller.
See [KVision examples](https://github.com/rjaros/kvision-examples) for more details. \ No newline at end of file
diff --git a/README.md b/README.md
index c72de672..5bcff07e 100644
--- a/README.md
+++ b/README.md
@@ -28,12 +28,15 @@ This design is quite similar to many non-web UI programming libraries including
- Includes convenient forms implementation, with support for many different input components and easy to use validation.
- Data binding support for [observable](https://github.com/rjaros/kotlin-observable-js) data model.
- Ready to explore [KVision examples](https://github.com/rjaros/kvision-examples) are available,
-built with [Gradle](https://gradle.org/) and supporting Webpack's [Hot Module Replacement (HMR)](https://webpack.js.org/concepts/hot-module-replacement/).
+built with [Gradle](https://gradle.org/) and supporting Webpack's [Hot Module Replacement (HMR)](https://webpack.js.org/concepts/hot-module-replacement/) and
+[Kotlin JavaScript DCE (dead code elimination)](https://kotlinlang.org/docs/reference/javascript-dce.html).
- [Karma](https://karma-runner.github.io/) testing framework support.
- IDE support (IntelliJ IDEA Community Edition).
## Getting started
+#### Development
+
1. Download [KVision examples](https://github.com/rjaros/kvision-examples) from GitHub:
git clone https://github.com/rjaros/kvision-examples.git
@@ -50,6 +53,17 @@ built with [Gradle](https://gradle.org/) and supporting Webpack's [Hot Module Re
4. Open [http://localhost:8088/](http://localhost:8088/) in your browser.
+5. Play with the code and see your changes immediately in the browser.
+
+#### Production
+
+To build complete application optimized for production run:
+
+ ./gradlew -Pprod=true distZip (on Linux)
+ gradlew.bat -Pprod=true distZip (on Windows)
+
+Application package will be saved as build/distributions/showcase.zip.
+
## Usage samples
### Hello world