Skip to content
This repository has been archived by the owner on Feb 4, 2022. It is now read-only.

Refactor View package #76

Merged
merged 6 commits into from
May 2, 2016
Merged

Refactor View package #76

merged 6 commits into from
May 2, 2016

Conversation

johanjanssens
Copy link
Member

resolve #75

- Move Viiew::getRoute() to new routable behavior and make it register the 'route()' template function
- Remove the 'escape' parameter from getRoute(), set the route escaping bin ViewTemplate::setUrl()
- Add getContent() method to ViewContextInteface, and pass and set the content in View::getContext()
- Make View class properties private and add ViewInterface::getMimetype()

BREAKING! The view class properties are now private. To migrate your code use the getter methods as defined in ViewInterface
@johanjanssens
Copy link
Member Author

@ercanozkaya Can you review please ? Question: do you think we should add a View::getVersion() method to make view versioning a first class citizen of a view ?

if ($fqr === true)
//Determine of the url needs to be fully qualified
if($this->getMixer()->getFormat() == 'html') {
$fqe = is_bool($fqr) ? $fqr : false;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@johanjanssens typo here. should be $fqr

@ercanozkaya
Copy link
Contributor

@johanjanssens Left two notes, good to go other than that.

I wouldn't add versioning support directly to the view. It's only useful for public facing APIs and even in that case there are different takes whether or not to use versions.

@johanjanssens johanjanssens merged commit 18afa9d into master May 2, 2016
@johanjanssens johanjanssens deleted the feature/75-view branch May 2, 2016 21:28
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Refactor View package
2 participants