mirror of https://github.com/status-im/reagent.git
Add README to example
This commit is contained in:
parent
0b1c7ffc33
commit
3e9b42a92b
|
@ -0,0 +1,7 @@
|
|||
# Reagent example app
|
||||
|
||||
Run "`lein figwheel`" in a terminal to compile the app, and then open example.html.
|
||||
|
||||
Any changes to ClojureScript source files (in `src`) will be reflected in the running page immediately (while "`lein figwheel`" is running).
|
||||
|
||||
Run "`lein clean; lein with-profile prod compile`" to compile an optimized version.
|
|
@ -2,18 +2,12 @@
|
|||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>reagent simple example</title>
|
||||
<title>Example</title>
|
||||
<link rel="stylesheet" href="example.css">
|
||||
</head>
|
||||
<body>
|
||||
<div id="app">
|
||||
<h1>Reagent example app</h1>
|
||||
|
||||
<p> Run "lein figwheel" in a terminal to compile, wait a while, and then refresh the browser. </p>
|
||||
|
||||
<p> Any changes to .cljs files will be reflected in the running page immediately. </p>
|
||||
|
||||
<p> Run "lein clean; lein with-profile prod compile" to compile an optimized version. </p>
|
||||
<h1>Reagent example app – see README.md</h1>
|
||||
</div>
|
||||
<script src="target/client.js"></script>
|
||||
<script>
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
|
||||
(ns simpleexample
|
||||
(:require [reagent.core :as reagent :refer [atom]]))
|
||||
|
||||
|
@ -32,5 +31,5 @@
|
|||
[color-input]])
|
||||
|
||||
(defn ^:export run []
|
||||
(reagent/render-component [simple-example]
|
||||
(reagent/render [simple-example]
|
||||
(js/document.getElementById "app")))
|
||||
|
|
Loading…
Reference in New Issue