I am creating a personal blog using node js and mongo db and implementing the function of writing posts.
I thought that the title and description of the post could be saved in the mongo db in String format, but I am curious about how to save the elements such as the image of the textarea and the font size.
I used tinyMCE as a text editor to write the content and the code is as follows.
<form action="/articles" method = "POST">
<h4>title</h4>
<input required type="text" name = "title" / class='form-control'><br>
<h4>description</h4>
<textarea name="description" class = 'form-control'></textarea><br>
<h4>contents</h4>
<textarea id="mytextarea" name="contents" rows = '10'></textarea>
<a href="/" class ="btn btn-secondary">취소</a><button type = "submit" class="btn btn-primary">저장</button>
</form>
And an example of a post is as follows.
I am wondering how can I save the contents of a textarea containing a picture in a db.