Code Monkey home page Code Monkey logo

Comments (7)

sahat avatar sahat commented on August 28, 2024

It is fine. I have given it much thought and looked at plenty of style guides and examples regarding namespacing so this is not too uncommon. Since I am no longer using ngAnnotate I have to inline annotate anyway.

Anything prefixed with satellizer. is not meant to be extendable or overridable, it is for internal usage only. Once AngularJS 2.0 comes around I will make all those services private.

from satellizer.

Foxandxss avatar Foxandxss commented on August 28, 2024

Alright, as always I respect your decisions, I just point out things that are more weird. I never saw that namespacing tbh and I done a lot of angular so far.

Leave it as is then, if it is not mean to be decorated by end users, good enough :)

from satellizer.

sahat avatar sahat commented on August 28, 2024

You might be right, I may have confused it with module namespacing notation, which is very common. Either way it's just an internal implementation detail.

We can discuss whether to keep it or switch to camelCase later, after all primary issues are fixed.

from satellizer.

Foxandxss avatar Foxandxss commented on August 28, 2024

Yes, module notation is different, but yes, let's talk about that after things are fixed.

from satellizer.

sahat avatar sahat commented on August 28, 2024

@Foxandxss If I namespace each service into its own module called satellizer.popup for example, and then require it in the main satellizer module like so:

angular.module('satellizer', ['satellizer.popup']);

Will satellizer.popup module be private if someone includes the main satellizer module in their app?

angular.module('MyApp', ['ngResource', 'ngMessages', 'ngRoute', 'satellizer', 'mgcrea.ngStrap'])

from satellizer.

stryju avatar stryju commented on August 28, 2024

no, it will be "public", so i can use it like:

angular.module('foo', ['satellizer.popup'])

can't really see how that causes an issue, tho :-)

from satellizer.

Foxandxss avatar Foxandxss commented on August 28, 2024

The thing is, why you need private? You don't. People will still inject "satellizer" to use the library, but if they need to inject the other inner services for something, let them do it!, You shouldn't restrict what they can do.

from satellizer.

Related Issues (20)

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.