Skip to content

Commit

Permalink
chore: added libraries for slider and dates
Browse files Browse the repository at this point in the history
  • Loading branch information
altrusl committed Oct 19, 2023
1 parent 41dbbcf commit 494c783
Show file tree
Hide file tree
Showing 4 changed files with 41 additions and 1 deletion.
19 changes: 19 additions & 0 deletions docs/development/misc.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,24 @@
# Полезные советы

::: details Какие есть хорошие библиотеки для работы с ...?

### Карусель или слайдер

[Keen-Slider](https://keen-slider.io/), [Embla Carousel](https://www.embla-carousel.com/), [Splide](https://splidejs.com/)

Хорошо известный [Swiper](https://swiperjs.com/) не очень подходит для Vue.js


### Дата и время

[day.js](https://day.js.org/), [day-fnc.js](https://date-fns.org/)

Известный [moment.js](https://momentjs.com/) безвозвратно устарел.

::: tip
Современный JavaScript - это гораздо больше, чем было 10 лет назад. В 95% случаев для операций с датой достаточно возможностей стандартного пакета JavaScript `Intl`
:::

::: details Как поймать момент когда пользователь доскролил до определенного места?

Intersection Observer
Expand Down
21 changes: 20 additions & 1 deletion docs/en/development/misc.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,24 @@
# Helpful hints

::: details What are some good libraries for working with ...?

### Carousel or slider

[Keen-Slider](https://keen-slider.io/), [Embla Carousel](https://www.embla-carousel.com/), [Splide](https://splidejs.com/)

Well known [Swiper](https://swiperjs.com/) is not so good for the Vue.js


### Date and time

[day.js](https://day.js.org/), [day-fnc.js](https://date-fns.org/)

Well known [moment.js](https://momentjs.com/) is irretrievably obsolete.

::: tip
Modern JavaScript is much more than it was 10 years ago. In 95% of cases the capabilities of the standard JavaScript `Intl` package are sufficient for date-time operations
:::

::: details How to catch the moment when the user scrolls to a certain place?

Intersection Observer
Expand Down Expand Up @@ -63,6 +82,6 @@ It works like `Ref` but does not track changes inside array elements, which give

::: details Mixins

We should forget about them like a bad dream. Mixins as a pattern of multiple inheritance is a very bad architectural practice and should be avoided. In Vue 2, the framework itself did not have a way to make the component part of the steit and methods common, so mixins were used. In Vue 3, the Composition API was introduced and mixins were no longer needed.
We should forget about them like a bad dream. Mixins as a pattern of multiple inheritance is a very bad architectural practice and should be avoided. In Vue 2, the framework itself did not have a way to make the component part of the steit and methods common, so mixins were used. In Vue 3, the Composition API has been introduced and mixins are no longer needed.

:::
1 change: 1 addition & 0 deletions docs/en/misc/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

- `Backend / CORS`
- `Frontend / How to learn Vue?`
- `Development / Useful tips`

<!-- --- -->

Expand Down
1 change: 1 addition & 0 deletions docs/misc/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@

- `Общение с бэкендом / CORS`
- `Фронтенд / Как изучать Vue?`
- `Разработка / Полезные советы`

<!-- --- -->

Expand Down

0 comments on commit 494c783

Please sign in to comment.