-
Notifications
You must be signed in to change notification settings - Fork 0
/
atom.xml
55 lines (42 loc) · 2.17 KB
/
atom.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
<title><![CDATA[Category: global id | machty's thoughtz]]></title>
<link href="http://machty.github.com/blog/categories/global-id/atom.xml" rel="self"/>
<link href="http://machty.github.com/"/>
<updated>2015-08-26T16:10:13-04:00</updated>
<id>http://machty.github.com/</id>
<author>
<name><![CDATA[Alex Matchneer]]></name>
</author>
<generator uri="http://octopress.org/">Octopress</generator>
<entry>
<title type="html"><![CDATA[Daily Journal]]></title>
<link href="http://machty.github.com/blog/2014/05/19/daily-journal/"/>
<updated>2014-05-19T07:38:00-04:00</updated>
<id>http://machty.github.com/blog/2014/05/19/daily-journal</id>
<content type="html"><![CDATA[<h2>Active Model: GlobalID</h2>
<p>https://github.com/rails/activemodel-globalid/</p>
<p>GlobalID is a way of serializing a model into a string so that
it can be looked up later; rather than serializing all of the
object's data into a string, you merely serialize just enough
information so that you can look up the rest.</p>
<p>I'm already doing something similar with model dep state in Ember,
only extending it such that part of the "GlobalID", which we'll
use internally for binding into a cache bucket, might be a prefixing
controller name to uniquely identify a cache bucket to a specific
controller, but in cases where you want to share information about
a model with other controllers, you'd leave this prefix off.</p>
<p>Anyway, nice to see other folk arriving at a similar thing, though
I personally wouldn't call this sort of thing "serializing" but rather
"paramaterizing", since you're not actually storing all the data in
string form but just enough to uniquely identify it so that some
other operation can restore the object.</p>
<h2>Strings have read-only props in "use strict" Safari</h2>
<p>The following throws an exception only in Safari (not Chrome or FF):</p>
<pre><code>(function(){"use strict"; ("a").b = 'writing to a string'; })();
TypeError: Attempted to assign to readonly property.
</code></pre>
<p>But not if you leave off the "use strict".</p>
]]></content>
</entry>
</feed>