Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Please add dependecy injection to src file #69

Open
Romick2005 opened this issue Jun 23, 2016 · 1 comment
Open

Please add dependecy injection to src file #69

Romick2005 opened this issue Jun 23, 2016 · 1 comment

Comments

@Romick2005
Copy link

Romick2005 commented Jun 23, 2016

Hi,

Can you please add injectors to src/angular-highlightjs.js file?

ngModule.factory('hljsCache', ['$cacheFactory', function ($cacheFactory) {

ngModule.controller('HljsCtrl', ['hljsCache', 'hljsService', '$interpolate', '$window', '$log',
function HljsCtrl (hljsCache, hljsService, $interpolate, $window, $log) {

hljsDir = ['$parse', function ($parse) {

Because I am using requireJs for dynamical loading. That's why i cannot use your root angular-highlightjs.js file. Because it require hljs. But I want use for example highlightJSPath not the hljs.

@pc035860
Copy link
Owner

Hi @Romick2005 ,

src/angular-highlight.js is not intended to be used in your code.
Maybe a non-UMD build will do?

build/angular-highlight.non-umd.js

(function (module) {
  /* content of src/angular-highlight.js */
})(angular.module('hljs', []));

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants