question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Feature Request: Provide a way to let user decide which FreshPageModelWrapper used

See original GitHub issue

Based upon Pullrequest #70 and #71

The motivation was that PageModel should be use Page name extension and ViewModel should be use View as name Extension. Because of a typo the ViewModel uses the Page name extension also. #70

Simple replacement of Page to View is not possible because it would be break a lot of application without update the code of the apps. (it make sense, or not) #71

looks to me like a workaround to solve the problem.

My Question (remember i am new on C#):

Why we could not simple use the IoC Pattern here? and let the user the choice to register a own Mapper?

public static IFreshPageModelMapper PageModelMapper { get; set; } = new FreshPageModelMapper();

With IoC ?

public static IFreshPageModelMapper PageModelMapper { get; set; } = FreshIOC.Container.Resolve<IFreshPageModelMapper>();

Issue Analytics

  • State:open
  • Created 7 years ago
  • Comments:6

github_iconTop GitHub Comments

3reactions
rjantz3commented, Jul 15, 2016

It is not clear in the documentation that you cannot have a naming convention of *ViewModel and *View. After stumbling around a while I realized I needed .Replace ("ViewModel", "View"); and NOT .Replace ("ViewModel", "Page");

1reaction
krisrokcommented, May 19, 2016

would work, but requires configuration. i’d expect it to “just work”.

and although it does not make much of a difference if things are called view or page, it just makes it easier for users – even more for users of other frameworks using “convention over configuration”.

we won’t be the last ones to stumble upon this, so hopefully something will happen about it… 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

What is a Feature Request? Understanding User Feedback
Feature requests are ideas, comments, messages, or specific customer inquiries asking for a particular function to be added to your product. Typically, a...
Read more >
What Is a Feature Request? Definition and Examples
A feature request is a comment, message, or ask from a user to implement a specific feature into your product. Feature requests can...
Read more >
Which Feature request to implement?
In general I like to select features that support the users' tasks. What are people trying to accomplish here? How can we make...
Read more >
How to Handle Customer Feature Requests [with Examples]
1. Identify your feature request sources · 2. Centralize your requests in a single place · 3. Respond personally and politely · 4....
Read more >
How to Manage and Write Feature Requests?
A feature request system is a place on the website where users can go to request features. These features will then be reviewed...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found