# Make a webapp framework/ecosystem as awesome as R's Shiny: a challenge to Julia's community

**URL:** <https://discourse.julialang.org/t/make-a-webapp-framework-ecosystem-as-awesome-as-rs-shiny-a-challenge-to-julias-community/9533>\
**Category:** Web Stack\
**Tags:** visualization, webapps\
**Created:** [March 6, 2018, 11:45am UTC](https://discourse.julialang.org/t/make-a-webapp-framework-ecosystem-as-awesome-as-rs-shiny-a-challenge-to-julias-community/9533 "2018-03-06T11:45:07Z")\
**Posts on this page:** 1\
**Showing post:** 40

<div class="post-metadata">

**Author:** ![sylvaticus](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/sylvaticus/32/203883_2.png) [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Post date:** [August 20, 2019, 8:21am UTC](https://discourse.julialang.org/t/make-a-webapp-framework-ecosystem-as-awesome-as-rs-shiny-a-challenge-to-julias-community/9533/40 "2019-08-20T08:21:54Z")

</div>

In 2019, Julia 1.x world, I found the combination of [Intract](https://github.com/JuliaGizmos/Interact.jl)+[Mux](https://github.com/JuliaWeb/Mux.jl) relatively simply for deploying an interacting model to the web _à-la_ Shiny, although the documentation of the two cited packages could still be improved…

```julia
using Interact,Plots,Mux

function myModel(p1,p2)
    xrange = collect(-50:+50)
    model = p1.*xrange .+ p2.* (xrange) .^2
    return model
end

function createLayout()
  p1s = slider(-50:50, label = "Par#1 (linear term):", value = 1)
  p2s = slider(-5:0.1:5, label = "Par#2 (quad term):", value = 1)

  mOutput = Interact.@map myModel(&p1s,&p2s)
  plt = Interact.@map plot(collect(-50:50),&mOutput, label="Model output")
  wdg = Widget(["p1" => p1s, "p2" => p2s], output = mOutput)
  @layout! wdg hbox(plt, vbox(:p1, :p2))
end

function serveLayout(port)
    try
      WebIO.webio_serve(page("/", req -> createLayout()), port)
    catch e
      if isa(e, IOError)
        # sleep and then try again
        sleep(0.1)
        serveLayout(port)
      else
        throw(e)
      end
    end
end

serveLayout(8001)

```

Resulting in:

 ![image](https://global.discourse-cdn.com/julialang/original/3X/8/a/8a93115462aad26d9b8c9e9b0ecdb7edfe08c215.png)

_Disclaimer: the code in this example is from an upcoming Apress book on Julia I am finalising… I am a bit confusing on copyrights, but I think I can still post it…_

---

_[View the full topic](https://discourse.julialang.org/t/make-a-webapp-framework-ecosystem-as-awesome-as-rs-shiny-a-challenge-to-julias-community/9533)._
