1.1.0
Table of Contents
Download

The View

The view file is located at resources/views/livewire/markdown-x.blade.php, and this is the file that displays all the front-end magic 🔮.

This file contains a good amount of code, which we may go into further detail later; however, if you modify this file upgrading to a new version may be a little difficult 👷.

But, hey, it's totally up to you 👇 If you want to take this editor and truly make it your own feel by adding more block items or more functionality, feel free. (but I can't promise support if it's heavily modified 😉)

One of the more important functions is getCursorXY(). This tracks the X and Y position of the cursor location. It works by creating a dynamic inline element with the same computed styles as the textbox. Determining the end of this dynamic element will give us the X and Y position of the cursor. There's more to this magic 🧙‍♂️, but that's the gist.