# Bootstrap 5 tags

I have been experimenting recently a lot with Bootstrap 5.  [Getting rid of jQuery](https://blog.lekoala.be/getting-rid-of-jquery) was a long overdue task, but now, I don't have the choice anymore :-)

## Reinventing the wheel

Well... if you need a kind of tagging system, you know probably  [Select2](https://select2.org/) . But... it requires jQuery.

So what about the alternatives ? A popular option is  [Choices](https://joshuajohnson.co.uk/Choices/) but did you see the size of that thing ? Annnd... its maintainer is not so active anymore.

What if we could create something ourselves ?

## Enter Bootstrap 5 tags

Actually, we have most of the things we already need in Bootstrap 5 : a dropdown menu, inputs, validation and badges... we just need to mix these together to create a nice little plugin.

Let's go straight to the demo:

%[https://codepen.io/lekoalabe/pen/ExWYEqx]

This plugin has two modes:
- One that only allows provided options and triggers a validation message if you try to type something else
- One that allow you to create new tags on the fly

It's still a bit "proof of concept" but it's been working pretty well so far.  [Keep posted by following and/or staring the repo](https://github.com/lekoala/bootstrap5-tags) .

## Pssst, there is more

I've also been working on  [making autogrowing textareas](https://codepen.io/lekoalabe/pen/gOmYaxm) ... it's a simple task really, but finding a nice plugin to do so... not so easy.  [Here is the repo](https://github.com/lekoala/vanilla-autogrow) .
