(“1000 levels deep” might seem like a lot, but it’s pretty realistic with React’s recursivelyTraversePassiveMountEffects. That’s how I ran into it – in TanStack Query!)
(“1000 levels deep” might seem like a lot, but it’s pretty realistic with React’s recursivelyTraversePassiveMountEffects. That’s how I ran into it – in TanStack Query!)
Just opening DevTools makes all timers 5-100× slower, due to the overhead of capturing stack traces. Even if you do nothing else (don’t record performance, etc)!
Guess who accidentally spent a weekend optimizing this 😅
(h/t @paul.irish for explaining why)
Just opening DevTools makes all timers 5-100× slower, due to the overhead of capturing stack traces. Even if you do nothing else (don’t record performance, etc)!
Guess who accidentally spent a weekend optimizing this 😅
(h/t @paul.irish for explaining why)
gist.github.com/iamakulov/85...
gist.github.com/iamakulov/85...
Just 100-200 of those in a row (trivial if you’re mounting a bunch of React components that set timers) will easily block the page.
Just 100-200 of those in a row (trivial if you’re mounting a bunch of React components that set timers) will easily block the page.
You can now throttle individual requests in Chrome!
Neat for experimenting with stuff like
- lazy-loading: does the UI look okay if this chunk takes MUCH longer to arrive
- resilience: what happens if this specific CDN is extremely slow
You can now throttle individual requests in Chrome!
Neat for experimenting with stuff like
- lazy-loading: does the UI look okay if this chunk takes MUCH longer to arrive
- resilience: what happens if this specific CDN is extremely slow
This wasn’t always easy! Some things, like stripping unnecessary <b>s that come from Google Docs, were simple:
This wasn’t always easy! Some things, like stripping unnecessary <b>s that come from Google Docs, were simple:
• ⌘V would do extra sanitization for Google Docs (to strip e.g. <b>s that it puts around everything ↓)
• HTML import/export would convert code blocks from <pre><code> into <template> (and back)
• etc
• ⌘V would do extra sanitization for Google Docs (to strip e.g. <b>s that it puts around everything ↓)
• HTML import/export would convert code blocks from <pre><code> into <template> (and back)
• etc
• You can type something, adding images or tables with a button
• You can ⌘V something from Notion, Google Docs, etc.
• You can import HTML with plugins
• You can type something, adding images or tables with a button
• You can ⌘V something from Notion, Google Docs, etc.
• You can import HTML with plugins
We’d still serialize code blocks into <template></template> that Framer uses. But inside that <template>, we’d put a <pre><code> tag that all other editors understand ↓
We’d still serialize code blocks into <template></template> that Framer uses. But inside that <template>, we’d put a <pre><code> tag that all other editors understand ↓
A month ago, if you tried to copy a code block from Framer to Notion, it would just not paste. It would be missing!
Reason? We serialized code blocks into our internal format, which other editors did not understand:
A month ago, if you tried to copy a code block from Framer to Notion, it would just not paste. It would be missing!
Reason? We serialized code blocks into our internal format, which other editors did not understand:
So shipping this required some careful API redesign + a lot of iteration on making it type-safe. E.g., one intermediate design:
So shipping this required some careful API redesign + a lot of iteration on making it type-safe. E.g., one intermediate design:
Framer has several separate text editors (CMS, canvas, etc). For ✨historical reasons✨, all these editors used *the same schema*. So if you added image support to CMS, you’d inadvertently add it to *every editor*.
This led to cute bugs:
Framer has several separate text editors (CMS, canvas, etc). For ✨historical reasons✨, all these editors used *the same schema*. So if you added image support to CMS, you’d inadvertently add it to *every editor*.
This led to cute bugs:
Story time!
Story time!
[1] issues.chromium.org/issues/4432...
[2] issues.chromium.org/issues/4367...
[1] issues.chromium.org/issues/4432...
[2] issues.chromium.org/issues/4367...
you could do it previously with libs like Quicklink, but it’s super cool to see this implemented natively
(it’s off by default, enabled with one html tag)
you could do it previously with libs like Quicklink, but it’s super cool to see this implemented natively
(it’s off by default, enabled with one html tag)