deloitteau / atlas Goto Github PK
View Code? Open in Web Editor NEWAtlas is the Deloitte Digital Framework for Sitecore Development
License: Other
Atlas is the Deloitte Digital Framework for Sitecore Development
License: Other
Hi,
I'm trying to get Atlas to work with Sitecore 9 and it's all well and good except the LinkFieldRenderingString class still has some dependency to CommonServiceLocator. In Sitecore 9, CommonServiceLocator is still used, but reserved for Solr integration only. This breaks on any ViewModel class that uses ILinkFieldRenderingString. The fix for this has already merge to the "develop" branch. It would be great if it could be merged to master, and release a new version of NuGet package.
Thanks,
David Nguyen
The test coverage in the project is a little... basic. We should add unit test coverage across all Atlas components, especially the mapper / field rendering components.
This class poses a very specific concern on a particular solution/implementation context and there fore shouldn't be held at the framework level. The full class name is DeloitteDigital.Atlas.FieldRendering.LinkFieldStyle.
In the IFieldRenderingString interface we have three methods, WithAttribute, DisableWebEdit, and DefaultValueIfEmpty.
These methods return IFieldRenderingString (the this
), and were intended to be builder methods to let the user build up the desired behaviour, e.g.
MyField.DisableWebEdit().DefaultValueIfEmpty("I'm empty!");
When you use these methods you are coerced to IFieldRenderingString
which can be annoying if your field was more derived, such as LinkFieldRenderingString
.
These methods would be better as extension methods, that use a generic parameter constrained to IFieldRenderingString. i.e.
public static T DisableWebEdit<T>(this T field) where T : IFieldRenderingString
This would allow the builder pattern on any of the field rendering types that derive from IFieldRenderingString
, without the coercion, e.g. after using DisableWebEdit()
the field is still a LinkFieldRenderingString and not a boring old IFieldRenderingString.
Changing the interface is a breaking change. Adding equivalent extension methods would help, but any code that references Atlas would have to be recompiled.
(placeholder - detail to be added)
LogScope emits Debug.WriteLine. We did this so we could see the logs while debugging.
The SitecoreTraceListener then writes the trace to the sitecore log file as well, results in duplicate logs.
I suggest the Debug.Write are removed.
I had a list of articles to be retrieved as I found out that for some of articles, url is mydomain.com/articles/article1 but for some other is like /sitecore/content/home/articles/article1
So I changed
return LinkManager.GetItemUrl(item);
With
return LinkManager.GetItemUrl(item, UrlOptions.DefaultOptions);
In one of the item extensions
public static Item GetFieldValueAsItem(this Item item, string fieldName)
securityDisabler is used. I would suggest that If someone needs SecurityDisabler they can useit in their own code.
Atlas is built against HtmlAgilityPack 1.4.9.5 but Sitecore ships with an earlier version. You currently need to manually install v 1.4.9.5 and add an assembly redirect.
This should be rectified, either by:
Sitecore introduced the concept of IRendererErrorStrategy. Instead of swapping out the ExecuteRenderer processor, we should move the functionality to a RendererErrorStrategy.
We have the need to use a Rendering Parameter template with a field of type GeneralLink.
Binding this field using a var of type IFieldRenderingString returns Null and using a var of type string, returns the xml for the link field.
We need a IFieldRenderingString or a Link object to be able to be returned so that it can be rendered and/or properties retrieved
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.