small refactoring
added inject method to library's views