-
Notifications
You must be signed in to change notification settings - Fork 114
Add task 3 #97
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
base: master
Are you sure you want to change the base?
Add task 3 #97
Conversation
| </h1> | ||
| <h2> | ||
| <%= "В расписании #{@trips.count} рейсов" %> | ||
| <%= "В расписании #{@trips.load.size} рейсов" %> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 👍 , явно и сразу понятно что происходит, загрузили в массив, взяли размер
| <% end %> | ||
| </ul> | ||
| <%= render "delimiter" %> | ||
| ==================================================== |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Можно ещё с рендерингом коллекций и даже указать шаблон для разделителя https://guides.rubyonrails.org/layouts_and_rendering.html#spacer-templates
| large.json - 8.34s | ||
| Разница драматическая, на этом эту часть заканчиваем | ||
|
|
||
| Поставил pg_hero - eму все нравится, полезной инфы - нет |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Хмм, обычно он подсказывает индексы создать, если погонять запросы
spajic
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💪
| *Какими ещё результами можете поделиться* | ||
| - Bullet ожидаемо утомителен | ||
| - RMP ожидаемо хорош | ||
| - паршиалы - красиво и архитектурно, но ни дороговато ли они стоят подчас? Это главный вывод для меня сегодня. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Можно оставить себе удобство паршлов если рендерить коллекцией https://guides.rubyonrails.org/layouts_and_rendering.html#rendering-collections
там не такая критичная просадка по производительности по сравнению с циклом
| } | ||
| end | ||
|
|
||
| Trip.import!(trips) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Чётко
No description provided.