I really like this post, but I'm wondering if you have a complete code example / project on GitHub that you could post here to give a little more context to the snippets. I'm trying to work through using this pattern and I'm having a bit of a hard time, but this post is perfect for what I need on my current project!
Lead Product Evangelist @Kentico, Founding partner @craftbrewingbiz. love to learn / teach web dev & software engineering, collecting vinyl records, mowing my lawn, craft 🍺
Thanks for the feedback and I'm glad the post is helpful.
I don't have any repo with the full picture of this implementation, but I'm planning on writing a follow up about generating URLs when using NodeAliasPath routing. Maybe I could put an example online then.
Was there a specific bit of code you were unsure about?
There shouldn't be too many pieces in then end...
NodeAliasPathConstraint
PageTypeRoute
Static PageTypeRouteAttributeCacheHelper class to do path -> Controller/Action name lookup
You can define these anywhere, though Kentico uses an \Infrastructure\ folder at the root of their MVC codebase and puts these cross-cutting or framework code pieces in there - I think that's a good pattern.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Sean,
I really like this post, but I'm wondering if you have a complete code example / project on GitHub that you could post here to give a little more context to the snippets. I'm trying to work through using this pattern and I'm having a bit of a hard time, but this post is perfect for what I need on my current project!
Thanks,
Jim Piller
Jim,
Thanks for the feedback and I'm glad the post is helpful.
I don't have any repo with the full picture of this implementation, but I'm planning on writing a follow up about generating URLs when using
NodeAliasPath
routing. Maybe I could put an example online then.Was there a specific bit of code you were unsure about?
There shouldn't be too many pieces in then end...
NodeAliasPathConstraint
PageTypeRoute
PageTypeRouteAttributeCacheHelper
class to do path -> Controller/Action name lookupYou can define these anywhere, though Kentico uses an
\Infrastructure\
folder at the root of their MVC codebase and puts these cross-cutting or framework code pieces in there - I think that's a good pattern.