Skip to content

::template(true) -- too much recursion #3

@dspinhirne

Description

@dspinhirne

Looking at your tests as examples for using the code and ran into an issue with templates. From your tests is seems that providing the "true" arg to a template should cause it to render automatically, however in practice this leads to a recursion error being raised. Using code from your basic test case, registering it, and using it in an html file:

var component1 = xtag.create(class extends XTagElement {
'::template(true)'(){
	return `<h1>title auto 1</h1><p>content auto 1</p>`;
}
});
xtag.register('x-component1', component1);


--
<x-component1></x-component1>

Raises this issue in the js console.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions