Feature request: add dominant color support
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 1.5k
- Forks
- 331
- Avg merge
- 19h 52m
- Merged PRs (30d)
- 9
Description
Especially when lazy-loading it is nice to have the dominant color as background of the layout-placeholder.
Would be nice as an option for <nuxt-image> and <nuxt-picture> and maybe exposing the dominant color for other usage aswell.
possible solutions to get the dominant color:
- https://www.npmjs.com/package/node-vibrant
- https://www.npmjs.com/package/dominant-color
- https://www.npmjs.com/package/color-thief
If you agree on adding this to @nuxt/image, I'd like to develop and propose a concept to you guys :) Would need more understanding of the module and vision of the module.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reviewing the @nuxt/image module and the and APIs to understand how image options and placeholder data are handled. Compare node-vibrant, dominant-color, and color-thief, then define how dominant color should work as a placeholder option and for other usage. Done should include an agreed concept for both components and exposed color data.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- nuxtjs, typescript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 28/100