Code Monkey home page Code Monkey logo

angular-disqus's People

Contributors

bestander avatar kirstein avatar ricterz avatar rsdntevl avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

angular-disqus's Issues

Does not seem to work at all anymore

I tried using this and it doesn't seem to recognize $disqusProvider at all

Here is what I did:

  1. bower install angular-disqus --save

  2. added ngDisqus

  3. tried to register the shortname.

(function(){

        'use strict';

        var dependencies = [
                'ghpg',
                'ngRoute',
                'ngDisqus'
        ];

        angular.module('blogger', dependencies)
        .config(Config);

        Config.$inject = ['$locationProvider', '$disqusProvider'];

        function Config($locationProvider){

                $locationProvider.hashPrefix('!');
                $locationProvider.html5Mode('true');
                $disqusProvider.setShortname('codeisdead');
        }

        if (window.location.hash === '#_=_'){
                window.location.hash = '#!';

        }


        //bootstrap angular

        angular.element(document).ready(function(){

                angular.bootstrap(document, ['blogger']);

        });



})();

Here is the error:

Failed to instantiate module blogger due to:
ReferenceError: $disqusProvider is not defined
    at Config (http://127.0.0.1:8080/angular/app.js:19:3)
    at Object.invoke (http://127.0.0.1:8080/js/lib/angular/angular.min.js:41:372)
    at d (http://127.0.0.1:8080/js/lib/angular/angular.min.js:39:321)
    at http://127.0.0.1:8080/js/lib/angular/angular.min.js:39:445
    at q (http://127.0.0.1:8080/js/lib/angular/angular.min.js:7:355)
    at g (http://127.0.0.1:8080/js/lib/angular/angular.min.js:39:222)
    at bb (http://127.0.0.1:8080/js/lib/angular/angular.min.js:43:246)
    at c (http://127.0.0.1:8080/js/lib/angular/angular.min.js:21:19)
    at Object.yc [as bootstrap] (http://127.0.0.1:8080/js/lib/angular/angular.min.js:21:332)
    at HTMLDocument.<anonymous> (http://127.0.0.1:8080/angular/app.js:32:11


Unable to get disqus to work properly

I've been unable to get this working properly, and have tried to following the instructions as best I could, however they are a bit lacking. A full example would go a long way!

I have followed the steps like this:

1.) angular.module('myApp', [ โ€ฆ, 'ngDisqus' ]);

2.) I could not get $disqusProvider.setShortname('shortname'); to work as I kept getting an exception stating that shortname is undefined, so used window.disqus_shortname

3.) I have tried to get my page_id into

without much luck.

I have tried disqus="{{ page_id }}" and disqus="page_id" and every combination I can think of without any luck.

If I hardcode an id eg: 7, disqus loads, however if I use another id, eg: 8 and open a different page, it loads the same discussion.

I see there is a function function setGlobals(id, url, shortname), but I'm unable to call it. Is this needed?

This looks like a very handy bit of code, but I am highly confused about how to use it, I would appreciate any help!!

Can't add the <script> to <head>

It's a good plugin! :)
I use it for my blog, but I can't load disqus comment.
I debuged and I think it don't add the script tag to <head>.

BTW, I manually added the <script src="http://go.disqus.com/embed.js"></script> to <head> and it load the disqus comment successfully, but the disqus comment is for http://moeloli.me rather than http://moeloli.me/#!/article/xxxxxx.

Thank you!

Set Page Title

When i use angular-disqus on my SPA, and someone writes a comment, the comment's title is not set. It would be nice to be able to specify the title of the current "page" directly on the directive.

Comment count

When I try the snippet from the README (with my settings of course) to show the comment count, I get the following javascript error:

Uncaught TypeError: Cannot call method 'appendChild' of null

in embed.js: 1.

This may be a disqus issue, but i simply don't know. Does it matter that I use the following (Jade) in a ng-repeat DIV?

a.title(ng-href="#!/news/{{item.id}}") {{item.title}}
a.label(ng-href="#!/news/{{item.id}}", data-disqus-identifier="{{item.id}}") &nbsp;

Use provider instead of window.shortname

It'd be great if this used a provider instead of window.shortname. This would allow the shortname to be defined within .config() in our applications to maintain good application structure.

License?

Hi, is there a license you want to apply to the repo?

Get comments count?

Hello! Can you help me to get comments count with this plugin?
Is this plugin has some method to help me with that?

Per Page option

Hi I would like to ask how to set 'per page' to limit the initial comments shown on load?

Not working with ng-repeat

I'm trying to display the discussion after each article on the page. But it is shown only on the first article.

  <main class="container container-last bg-transparent-white padding3">
    <div class="row" ng-repeat="nomine in battleTatamiController.nomines" class="nomine-entry">
     ...

            <div class="row">
              <div class="col-xs-12">
               <div disqus="photoshop-battle"></div>
              </div>
            </div>

          </section>
        </article>
        <hr/>
      </div>
    </div>

  </main>

Disqus showing the same thread

I have followed README and added following on my page template

   <div disqus="app._id"></div>

However, no matter which page I visit (with different app._id), I see the same Disqus thread. Is there a common cause of this problem?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.