Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

10

Share

Download to read offline

Getting Started With Datascript and Reagent

Download to read offline

Quick introduction on how to use Datascript with Reagent to build web applications.

Given to the Cambridge NonDysFunctional Programmers Meetup on November 13th 2014.

Related Books

Free with a 30 day trial from Scribd

See all

Related Audiobooks

Free with a 30 day trial from Scribd

See all

Getting Started With Datascript and Reagent

  1. 1. Getting started with Datascript & Reagent for webapps Brice Fernandes @fractallambda brice@fractallambda.com tiny.cc/reactive-datascript
  2. 2. DataScript: Datomic-like queries on Clojurescript browser objects Reagent: Clojurescript wrapper around Facebook’s React.js reactive UI library
  3. 3. Hints Use lein  cljsbuild  auto to rebuild whenever your files are modified Create a new tabset in LightTable: ^-space then search for Tabset: Add a tablet Create a browser tab in LightTable: ^-space then search for Browser: Add browser tab
  4. 4. Rendering to the page1 Reagent Atoms are special2 Enter Datascript3 Binding Datascript & Reagent4 Fun with Datascript5
  5. 5. Your turn. Make a basic profile page for a dog
  6. 6. Rendering to the page1 Reagent Atoms are special2 Enter Datascript3 Binding Datascript & Reagent4 Fun with Datascript5
  7. 7. Your turn. Let a dog change mood by clicking a button
  8. 8. Rendering to the page1 Reagent Atoms are special2 Enter Datascript3 Binding Datascript & Reagent4 Fun with Datascript5
  9. 9. … …
  10. 10. Listing all dogs
  11. 11.
  12. 12. Dog Match-Making
  13. 13. … …
  14. 14. Your turn. Match male dogs of similar age (~1 year) into packs and list possible packs
  15. 15. Datomic Query Docs: http://docs.datomic.com/query.html Datascript Test Examples: http://tiny.cc/datascript-test Datalog/Datascript Tutorial: http://www.learndatalogtoday.org/
  16. 16. ! What Happens when you change the DB?
  17. 17.
  18. 18. :(Nothing…
  19. 19. Rendering to the page1 Reagent Atoms are special2 Enter Datascript3 Binding Datascript & Reagent4 More Fun with Datascript5
  20. 20. … …
  21. 21. 1 2
  22. 22. Your turn. Update 1) The members count 2) The pairings
  23. 23. Rendering to the page1 Reagent Atoms are special2 Enter Datascript3 Binding Datascript & Reagent4 Fun with Datascript5
  24. 24. Your turn. Add to the app :-) Suggest looking at one:many relations (parents / child)
  25. 25. Brice Fernandes @fractallambda brice@fractallambda.com tiny.cc/reactive-datascript ? Bind and Unbind Function from https://gist.github.com/allgress/11348685
  • ThinhPTran

    Nov. 23, 2016
  • ZacharyLarson2

    Mar. 1, 2016
  • damienkstanton

    Jul. 27, 2015
  • Dudnik

    Jul. 17, 2015
  • mkunikowski

    Apr. 26, 2015
  • obcanhromadka

    Mar. 28, 2015
  • SangKyuPark1

    Mar. 7, 2015
  • odekopoon

    Jan. 28, 2015
  • ssuser0c0dcd

    Dec. 16, 2014
  • fractallambda

    Nov. 13, 2014

Quick introduction on how to use Datascript with Reagent to build web applications. Given to the Cambridge NonDysFunctional Programmers Meetup on November 13th 2014.

Views

Total views

5,185

On Slideshare

0

From embeds

0

Number of embeds

648

Actions

Downloads

18

Shares

0

Comments

0

Likes

10

×