Skip to content

Instantly share code, notes, and snippets.

@mycolaos
mycolaos / file structure
Last active March 2, 2023 15:06
initial file structure
/src
index.js
/dist
index.html
# bundle.js will be created automatically when you run `npm run build`
package.json
@mycolaos
mycolaos / index.html
Created August 30, 2017 12:16
SPA html
<!doctype html>
<html>
<head>
<title>Fearless</title>
</head>
<body>
<div id='root'></div>
<script src='bundle.js'></script>
</body>
</html>
@mycolaos
mycolaos / CreatableAutocomplete.tsx
Last active February 1, 2024 15:42
Creatable Autocomplete simplifying the MUI Autocomplete usage.
/**
* This is a CreatableAutocomplete component that can be used to create new
* options using MUI's Autocomplete component.
*
* Motivation: the MUI interface for creatable autocomplete is complex and hard
* to follow, this component simplifies the interface by separating the event of
* selecting an option from the event of creating a new option.
*
* Usage copy-paste it and use it like this:
*