In this post I wanted to share a simple solution to save any level of nested categories in a MySQL database table and retrieve them using Laravel Eloquent models and their relationships. This means that you’ll be able to store and retrieve any number of categories > subcategories > sub subcategories… (you get the idea) using one database table.
Category: Web Development
Tutorials, guides and knowledge related to web development and its technologies, frameworks, tools, services and more.
Before you start reading the main content of this post I wanted to let you know that this is the second part of a posts’ series on learning Angular, so if you are coming directly to this post you might want to check the first part where I cover some of the Angular basic concepts.
In this post I’ll cover some concepts that will help you use the properties and methods from your components classes in your components templates and also I’ll show you how to hook into different moments of the lifecycle of a component.
What is Angular?
Angular is an open-source frontend framework created at Google. It facilitates the creation of Single Page Applications (SPA) through its many of functionalities and concepts.
An important note to know is that “Angular” is a totally different framework from “Angular.js”. While Angular.js refers to the version 1.x of the framework, Angular is a complete rewrite of the framework starting in version 2.x and currently going at version 8.x.
What is TypeScript?
TypeScript is a superset of JavaScript developed and maintained as open source software by Microsoft. What superset means, more simply, is additional syntax and functionalities added on top of JavaScript.
Before you stop reading this post because the title says 2015 I wanted to let you know that this guide starts on new features implemented in ECMAScript 2015 because this version was a big step from the previous one (ECMAScript 2009) Also new features implemented in ES2015 are the standard used in current technology and new versions of the standard are develop based on ECMAScript 2015. In any case I’m always trying to keep the guide updated with new features implemented in most recent versions.