Skip to content

A couple of small size optimizations #810

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
Sep 18, 2019
Merged

A couple of small size optimizations #810

merged 6 commits into from
Sep 18, 2019

Conversation

justinfagnani
Copy link
Contributor

@justinfagnani justinfagnani commented Sep 16, 2019

  • Use _updateComplete Promise to wait for first connection
  • Optimize _enqueueUpdate for size a bit
  • Inline _markUpdated
  • Inline and combine style flattening and de-duplication

Before:

┌─────────────────────────────────────────┐
│                                         │
│   Destination: lit-element.bundled.js   │
│   Bundle Size:  21.04 KB                │
│   Minified and Gzipped Size:  6.75 KB   │
│   Brothli size: 6.13 KB                 │
│                                         │
└─────────────────────────────────────────┘

After:

┌─────────────────────────────────────────┐
│                                         │
│   Destination: lit-element.bundled.js   │
│   Bundle Size:  20.7 KB                 │
│   Minified and Gzipped Size:  6.65 KB   │
│   Brothli size: 6.04 KB                 │
│                                         │
└─────────────────────────────────────────┘

@justinfagnani justinfagnani changed the base branch from master to travis September 16, 2019 22:24
@justinfagnani justinfagnani changed the base branch from travis to master September 16, 2019 23:23
@sorvell sorvell merged commit 78e19f4 into master Sep 18, 2019
@sorvell sorvell deleted the has-connected branch September 18, 2019 18:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants