How to register a template in [NEW] WordPress site editor through a plugin

Two of the best ways to do this are (1) by using Create Block Theme plugin or a (2) Child theme. Why complicate it with a new plugin?

In the child theme, create a templates folder, and in that, add a custom-template.html file.

You can also add a new template by using the Plus + button on top to add a new template and export it as either a new theme or as a child theme using Create Block Theme

Create a New Template

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)