Conversation
spajic
approved these changes
Mar 20, 2025
| uses: actions/checkout@v3 | ||
|
|
||
| - name: Run sitespeed.io | ||
| uses: docker://sitespeedio/sitespeed.io:latest |
Collaborator
There was a problem hiding this comment.
лучше конкретную версию (lastest на текущий момент), чтобы не было непредсказуемых изменений
| Vendor до оптимизаций: | ||
|  | ||
|
|
||
| devtool coverage показывает, что ~60% js не используется |
Collaborator
There was a problem hiding this comment.
👍 угнетающая история конечно, загрузили чисто 60% ненужного чего-то
| ```JavaScript Transfer Size with value 452.2 KB limit max 449.2 KB``` | ||
|
|
||
| у chartjs-color тоже есть зависимости, одна из них chartjs-color-string, уберем их (!/chartjs-color/.test(module.context)): | ||
| ```JavaScript Transfer Size with value 452.1 KB limit max 449.2 KB``` АААААА |
|  | ||
|
|
||
| ## Результаты | ||
| в результате оптимизации удалось уменьшить объем загружаемого js на главной странице с 1.0 MB до 448.0 KB и уложиться в бюджет 449.2 KB |
| в результате оптимизации удалось уменьшить объем загружаемого js на главной странице с 1.0 MB до 448.0 KB и уложиться в бюджет 449.2 KB | ||
|
|
||
| ## Защита от регрессии производительности | ||
| Для защиты от потери достигнутого прогресса при дальнейших изменениях программы был настроен CI |
| return module.context && module.context.indexOf('node_modules') !== -1 | ||
| return module.context && | ||
| module.context.indexOf('node_modules') !== -1 && | ||
| !/chart|moment|color-name|color-convert/.test(module.context) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
CI: https://github.com/elenachekhina/rails-optimization-task6/actions/runs/13884193376