You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
And I've been thinking, that while the template can be loaded to the new file with the copyFile endpoint, I think it would be much lighter if the content of the file was retrieved from the template.
With the content it is much easier to reset the file to the template which is a functionality that is currently with the default code of each file.
I propose to add an endpoint where given a file it returns the content in plain text. So, when the page is rendering, retrieve the template and only set the value for the editor, the handleInsertFileTemplate can be reused.
The text was updated successfully, but these errors were encountered:
TalkySafe143
changed the title
Adding get doc content enpoint for IDE custom templates
Adding get doc content endpoint for IDE custom templates
Jan 24, 2024
I'm actually working on cpinitiative/ide#33
And I've been thinking, that while the template can be loaded to the new file with the copyFile endpoint, I think it would be much lighter if the content of the file was retrieved from the template.
With the content it is much easier to reset the file to the template which is a functionality that is currently with the default code of each file.
I propose to add an endpoint where given a file it returns the content in plain text. So, when the page is rendering, retrieve the template and only set the value for the editor, the handleInsertFileTemplate can be reused.
The text was updated successfully, but these errors were encountered: