Experiment with FAQ formatting

This commit is contained in:
Mike Thompson 2016-08-29 23:06:41 +10:00
parent 8260e41c60
commit 781e7ca323
5 changed files with 18 additions and 10 deletions

View File

@ -1,9 +1,9 @@
## Question
### Question
How can I inspect the contents of `app-db`? Perhaps from figwheel.
## Short Answer
### Short Answer
If at a REPL, inspect: `re-frame.db/app-db`.
@ -12,7 +12,7 @@ If at the js console, that's `window.re_frame.db.app_db.state`.
You are [using clj-devtools](https://github.com/binaryage/cljs-devtools), right?
If not, stop everything and immediately make that happen.
## Better Answer
### Better Answer
Are you sure you need to?
@ -55,4 +55,5 @@ or
You definitely have [clj-devtools](https://github.com/binaryage/cljs-devtools) installed now, right?
---
Up: [FAQ Index](README.md)      

View File

@ -2,7 +2,7 @@
I use logging method X, how can I make re-frame use my method?
## Answer
### Answer
re-frame makes use of the logging functions: `warn`, `log`, `error`, `group` and `groupEnd`.
@ -22,3 +22,6 @@ override that by providing your own set or subset of these functions using
:log my-log
...})
```
---
Up: [FAQ Index](README.md)      

View File

@ -1,9 +1,9 @@
## Question
### Question
If I `dispatch` a js event object (from a view), it is nullified
by the time it gets to the event-handler. What gives?
## Answer
### Answer
So there's two things to say about this:
- if you want to `dispatch` a js event object to a re-frame
@ -15,3 +15,7 @@ So there's two things to say about this:
and `dispatch` that, rather than the js event object itself. When you
`dispatch` pure, simple cljs data (ie. rather than js objects) testing
and debugging will become easier.
---
Up: [FAQ Index](README.md)      

View File

@ -4,7 +4,6 @@
2. [How do I use logging method X](Logging.md)
3. [Dispatched Events Are Null](Null-Dispatched-Events.md)
4.
5.
6. [Why implement re-frame in `.cljc` files](Why-CLJC.md)

View File

@ -1,9 +1,9 @@
## Question
### Question
Why is re-frame implemented as `.cljc` file? Aren't ClojureScript
Why is re-frame implemented in `.cljc` files? Aren't ClojureScript
files meant to be `.cljs`?
## Answer
### Answer
So tests can be run on both the JVM and the JS platforms,
re-frame's implementation is mostly in `.cljc` files.
@ -16,4 +16,5 @@ Necessary interop for each platform can be found in
See also: https://github.com/Day8/re-frame-test
---
Up: [FAQ Index](README.md)