Giter VIP home page Giter VIP logo

kfsad's Introduction

WARNING This repo is frozen to be in touch with original presentation. There is a new repository under Kotlin with actual Kotlin version and Kotlin/JS Gradle plugin.

kotlin-full-stack-application-demo

A full-stack demo application written in Kotlin for JetBrains Night Moscow 2019. Presentation video in Russian.

Description

This application displays a feed containing user-generated posts and comments. All data is stubbed by the fakeJSON and JSON Placeholder services.

It is a Kotlin Multiplatform project.

It uses:

During application startup posts are preloaded to the in-memory database from the fakeJSON (or JSON Placeholder) service. When the user requests the page, several posts are selected from the DB and the corresponding comments are fetched via the multi-platform HTTP client. Posts with comments are served to the client via RPC. After the initial render is done, information about authors is fetched via the client-side HTTP client and rendered after all coroutines terminate successfully. The "Load more comments" button fetches additional comments for the post using the multi-platform HTTP client.

This application has no error handling and has very limited RPC serialization. It's not meant for production use and serves only as a technology example.

Useful Gradle tasks

gradle run runs webpack-dev-server and the Ktor application. You can find logs at build/logs.

gradle stop stops webpack-dev-server and the Ktor application.

gradle bundle to create static files bundle.

gradle webpack-run runs webpack-dev-server only.

gradle webpack-stop stops webpack-dev-server only.

gradle ktor-run runs the Ktor application only.

gradle ktor-stop stops the Ktor application only.

gradle jvmTest to run common and JVM tests with JUnit.

gradle runKarmaTests to run common and JS tests with Mocha and Karma.

Hosts

webpack-dev-server responds at http://0.0.0.0:8080, the Ktor application responds at http://0.0.0.0:8081.

Contact information

Feel free to contact me via:

Pull requests are welcome!

kfsad's People

Contributors

leonya avatar mkraynov avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

kfsad's Issues

An example of redux usage

Hi. Nice speech you're giving right now. Could you please add Redux to the project? I've had some issues with Redux with Kotlin JS in the past, but I'm not a real frontend developer, so it would be nice to have here an example of Redux usage since it's so popular in JS world.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.