In React's terminology, there are five core types that are important to distinguish:
React Elements
| # This gist is compatible with Ansible 1.x . | |
| # For Ansible 2.x , please check out: | |
| # - https://gist.github.com/dmsimard/cd706de198c85a8255f6 | |
| # - https://github.com/n0ts/ansible-human_log | |
| # This program is free software: you can redistribute it and/or modify | |
| # it under the terms of the GNU General Public License as published by | |
| # the Free Software Foundation, either version 3 of the License, or | |
| # (at your option) any later version. | |
| # |
| module main | |
| {- | |
| I assume you're coming here from | |
| http://chromaticleaves.com/posts/idris-and-dependent-types.html | |
| If not, please take a moment to read it. It's a very important white paper. | |
| Completely serious, too. | |
| Now that we have that out of the way, this gist is a contrived example that |
| (* Purely functional I/O in Ocaml via the Free monad. | |
| * by Ricky Elrod <[email protected]>. | |
| * | |
| * This is free and unencumbered software released into the public domain. | |
| * | |
| * Anyone is free to copy, modify, publish, use, compile, sell, or | |
| * distribute this software, either in source code form or as a compiled | |
| * binary, for any purpose, commercial or non-commercial, and by any | |
| * means. | |
| * |
| var Dialog = React.createClass({ | |
| render: function() { | |
| // 1) render nothing, this way the DOM diff will never try to do | |
| // anything to it again, and we get a node to mess with | |
| return React.DOM.div(); | |
| }, | |
| componentDidMount: function() { | |
| // 2) do DOM lib stuff | |
| this.node = this.getDOMNode(); |
| @binkmail.com | |
| @bobmail.info | |
| @chammy.info | |
| @devnullmail.com | |
| @letthemeatspam.com | |
| @mailinater.com | |
| @mailinator.net | |
| @mailinator2.com | |
| @notmailinator.com | |
| @reallymymail.com |
In React's terminology, there are five core types that are important to distinguish:
React Elements
| function makeStyle(defaults, tagName) { | |
| tagName = tagName || 'div'; | |
| var Style = React.createClass({ | |
| getDefaultProps: function() { | |
| return assign({}, defaults); | |
| }, | |
| render: function() { | |
| var style = assign({}, this.props); | |
| delete style.children; |
2015-01-29 Unofficial Relay FAQ
Compilation of questions and answers about Relay from React.js Conf.
Disclaimer: I work on Relay at Facebook. Relay is a complex system on which we're iterating aggressively. I'll do my best here to provide accurate, useful answers, but the details are subject to change. I may also be wrong. Feedback and additional questions are welcome.
Relay is a new framework from Facebook that provides data-fetching functionality for React applications. It was announced at React.js Conf (January 2015).
| (define construct-environment | |
| Globals -> [do | (global-load-sequence Globals)]) | |
| (define global-load-sequence | |
| [] -> [] | |
| [Name | Names] -> [[set Name (construct-value (value Name))] | |
| | (global-load-sequence Names)]) | |
| (define atom? | |
| X -> (or (boolean? X) |
| * { | |
| font-size: 12pt; | |
| font-family: monospace; | |
| font-weight: normal; | |
| font-style: normal; | |
| text-decoration: none; | |
| color: black; | |
| cursor: default; | |
| } |