Questions tagged [aurelia-templating]

Part of the Aurelia platform and contains an extensible HTML templating engine supporting databinding, custom elements, attached behaviors and more.

87 questions
1
vote
1 answer

Copy all attributes from custom element into template in Aurelia

When you are creating a custom element in Aurelia, is there a way to take all of the extra attributes that aren't bound and copy them to a specific element inside the template. For example, say I create a custom element called "my-custom-element"…
John White
  • 19
  • 3
1
vote
1 answer

How to use static methods in view templates

I want to use static class constants in my view template Javascript class FilterModel { static const FILTER_TYPE_STRING() { return 'string'; } } HTML
Mike Reiche
  • 382
  • 3
  • 12
1
vote
1 answer

Aurelia: Is there any option / decorator to restrict an attribute to a specific element

Hi I have created a custom element named as 'panel' and a custom attribute 'panel-type'. I want to restrict this 'panel-type' can be used only in 'panel' element. Is there any way to do that?
Tuhin
  • 3,335
  • 2
  • 16
  • 27
1
vote
1 answer

Aurelia compose with globalResources

Our plan is the following: A dashboard with webparts. We plan on develop many different "webparts" (as custom elements), and later, based on role or preferences we will show just a selection of the availible webparts. Say I have the following custom…
Larsi
  • 4,654
  • 7
  • 46
  • 75
1
vote
1 answer

How to tear down an enhanced fragment

I am working on an existing SPA where we replace components with Aurelia components step by step. We use the enhance API of the TemplatingEngine. That works pretty well but we also need to tear down those enhanced fragments (remove event listeners,…
1
vote
2 answers

Repeating with custom elements performance issues in IE

We have some performance issues with IE10/11. The following plunker explains some of our degrading performance while repeating table rows with custom elements. Plunker Example code In this plunker example, we get a total of 68 ms in chrome to…
Anders
  • 878
  • 1
  • 9
  • 20
1
vote
0 answers

is it necessary to define a template in a separate file?

Is it possible to compose a template defined in the same file, like the following. Or is it required that the composed template be contained in a separate file?