I have a <div> with contenteditable=true and I'd like to use components 
inside this div to give some of the contents specific behaviors. 
Essentially these components are <span>s with some data binding and css 
styling.

I need to be able to create these components, at any location within the 
div, based on server and user activity. I can't just put the 
<my-component....> tag in the innerHTML. I've looked at 
DynamicComponentLoader which *almost* looks like it will do the right 
thing, but it needs a template variable to mark the spot to place the 
component. But I can't find a way to insert a template variable, either. 
Putting <span #marker></span> in the innterHTML doesn't work.

My next step is to start looking at the TemplateCompiler, but I'm starting 
to feel like I'm fighting Angular instead of leveraging it.

Is there a pattern for how code can easily insert Angular components into 
the DOM, dynamically at runtime?

-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at https://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to