JavaScript Arrays are a very flexible data structure and used as lists, stacks, queues, tuples (e.g. pairs), etc. Some
Creating Arrays, reading and writing elements:
# Best practices and conventions | |
This guide contains best practices and conventions for building an administration extension. | |
## Component conventions | |
- Each component should be as slim as possible. | |
- The component stands for its own and fulfills only one purpose. It is better to make multiple smaller components than putting too much complexity into a single component. | |
- The component contains not much logic. Complex logic is handled by the modules. | |
### Properties order | |
The properties of a component should have the following order: |
/* | |
* Handling Errors using async/await | |
* Has to be used inside an async function | |
*/ | |
try { | |
const response = await axios.get('https://your.site/api/v1/bla/ble/bli'); | |
// Success 🎉 | |
console.log(response); | |
} catch (error) { | |
// Error 😨 |