dtpublic/malhar-angular-dashboard

Trying to run malhar angular dashboard on my local:[Windows 7]

Closed this issue · 4 comments

Hello everbody,

I am trying to run malhar angular dashboard on my local.
When using grunt, I get the jquery and localstorage not defined.
Any help would be appreciated.

D:\malhar-angular-dashboard>grunt
Running "clean:dist" (clean) task

0 paths cleaned.

Running "jshint:all" (jshint) task

 51 |        jQuery.extend(true, widget, result);
             ^ 'jQuery' is not defined.
103 |        jQuery.extend(true, widget, result);
             ^ 'jQuery' is not defined.
122 |    $scope.result = jQuery.extend(true, {}, widget);
                         ^ 'jQuery' is not defined.

 24 |      storage: localStorage,
                    ^ 'localStorage' is not defined.
 45 |      storage: localStorage,
                    ^ 'localStorage' is not defined.

5 errors in 9 files
Warning: Task "jshint:all" failed. Use --force to continue.

Aborted due to warnings.

Execution Time (2016-02-12 14:15:42 UTC)
clean:dist 16ms ████████ 6%
jshint:all 218ms ███████████████████████████████████████████████████████████████████████████████████████████████████████████ 87%
Total 250ms

I'm not so well-versed in the usage of grunt; however in my index.html file I have referenced jQuery:

         <script src="Scripts/jquery/jquery.min.js"></script>

But in the case of localStorage - I don't see why it would fail on that. It's inherent to the browser from my understanding.

Can you provide the file names in which you are seeing those errors ? i.e. the dashboard-directive.js file ?

Bob

Hello robert,

The files are D:\malhar-angular-dashboard\src\app\customWidgetSettings.js having JQuery error.
and D:\malhar-angular-dashboard\src\app\layouts.js having localStorage error.

When I put jquery and put it in D:\malhar-angular-dashboard\src\app where is index.html and refererence in index.html as <script src="jquery-1.12.0" ></script>

Then using grunt again I get this error:-

D:\malhar-angular-dashboard>grunt
Running "clean:dist" (clean) task

0 paths cleaned.
Running "jshint:all" (jshint) task

52 | jQuery.extend(true, widget, result);
^ 'jQuery' is not defined.
104 | jQuery.extend(true, widget, result);
^ 'jQuery' is not defined.
122 | $scope.result = jQuery.extend(true, {}, widget);
^ 'jQuery' is not defined.

23 | storage: localStorage,
^ 'localStorage' is not defined.
43 | storage: localStorage,
^ 'localStorage' is not defined.

636 | push_native = arr.push,
Warning: Invalid array length Use --force to continue.

Aborted due to warnings.

Execution Time (2016-02-14 06:58:41 UTC)
loading tasks 12ms █ 1%
clean:dist 43ms ██ 4%
jshint:all 1.1s █████████████████████████████████████████████ 95%
Total 1.1s

Do note that last error which is in jquery file.

wvary commented

@AviralSri I'm on a mac and use gulp.
Have you tried "gulp serve"?

wvary commented

Close issue due to in-activity.
We'll revisit the issue if @AviralSri re-open the the issue.