From 6f6f4112411b02b61d2df6fd7aa3c8158907ab5f Mon Sep 17 00:00:00 2001 From: Simon Reinisch Date: Sat, 22 Oct 2022 15:12:16 +0200 Subject: [PATCH] Update README with goal of library Closes #179 --- README.md | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 46923a1..dddf0c4 100644 --- a/README.md +++ b/README.md @@ -45,6 +45,7 @@

### Features 🤘 + * 🌟 Modern bundle * 🔩 Ultra tiny (<4kb) * 👌 Simple usage @@ -59,7 +60,8 @@ Check out the documentation for the package you want to use: -* [@viselect/vanilla](packages/vanilla) ([demo](https://codesandbox.io/s/viselectvanilla-kt332?file=/src/main.ts)) - To be used with plain [JavaScript](http://vanilla-js.com/) or [TypeScript](https://www.typescriptlang.org/). +* [@viselect/vanilla](packages/vanilla) ([demo](https://codesandbox.io/s/viselectvanilla-kt332?file=/src/main.ts)) - To be used with plain [JavaScript](http://vanilla-js.com/) + or [TypeScript](https://www.typescriptlang.org/). * [@viselect/preact](packages/preact) ([demo](https://codesandbox.io/s/viselectpreact-kjo9e?file=/src/app.tsx)) - [Preact](https://preactjs.com/) wrapper. * [@viselect/react](packages/react) ([demo](https://codesandbox.io/s/viselectreact-sbn83?file=/src/App.tsx)) - [React](https://reactjs.org/) wrapper. * [@viselect/vue](packages/vue) ([demo](https://codesandbox.io/s/viselectvue-x13g6?file=/src/App.vue)) - [Vue3](https://v3.vuejs.org/) wrapper. @@ -73,11 +75,20 @@ Check out the documentation for the package you want to use: ### Browser support This library will always have the previous year as its target. For 2021 for example the target will be ES2020. -It always provides both a `UMD` (`.js`) and `.mjs` version. If you want to support legacy browsers, please use the feature of your bundler to transpile dependencie. In case of webpack and babel (give [vite](https://vitejs.dev/) a try, it's awesome) you'll have to install corresponding plugins such as [babel-plugin-proposal-optional-chaining](https://babeljs.io/docs/en/babel-plugin-proposal-optional-chaining) and include the dependency from `node_modules` which is normally entirely excluded from being processed. +It always provides both a `UMD` (`.js`) and `.mjs` version. If you want to support legacy browsers, please use the feature of your bundler to transpile dependencie. In case of +webpack and babel (give [vite](https://vitejs.dev/) a try, it's awesome) you'll have to install corresponding plugins such +as [babel-plugin-proposal-optional-chaining](https://babeljs.io/docs/en/babel-plugin-proposal-optional-chaining) and include the dependency from `node_modules` which is normally +entirely excluded from being processed. I do this to provide maximum flexibility and give those who target ESNext a chance to make full use of how this library is bundled. Everything else is just a matter of configuration :) +### Is this library the right choice for me? + +Viselect primarily focuses on being a high-performant engine to select elements with various boundaries, behaviours and modes in your browser. +Viselect is to "full-blown libraries" what is [popper.js](https://popper.js.org/) to [tippy.js](https://atomiks.github.io/tippyjs/) - the _core_ of your feature / of another +library. + ### Development Use the following commands to work on this locally (we use [lerna](https://lerna.js.org/) to manage this):