asp.net mvc - Define Custom Attributes for Spark View Engine -


is there way (preferably without modifying source) can define custom attribute apply spark elements?

for example, i'd define "permission" attribute can like:

<div permission="canviewdivs">  </div> 

which map specific bit of code determine if current user can view divs , hide if not.

i know condition attribute , spark bindings, these don't quite accomplish want.

the answer "no" i'm afraid. this, we'd have have kind of schema we'd feed special node parser , compiler, , don't see tenable or pragmatic unless can convince me otherwise :)

happy @ use cases in more depth , decide if it's kind of thing can added. dave said in comment, kind of visual logic should come view models, or @ least that's way build projects. you're letting users edit templates , you've got rendering subsystem behind imagine why you're asking in first place - i.e. want give more power users without having recompile software...

this sadly don't think view engine should responsible for, said, i'd happy chat possible use cases...

you know how in touch...

cheers,
rob


Comments

Popular posts from this blog

c# - How to set Z index when using WPF DrawingContext? -

razor - Is this a bug in WebMatrix PageData? -

visual c++ - Using relative values in array sorting ( asm ) -