Giter Club home page Giter Club logo

Comments (8)

futuresplash avatar futuresplash commented on May 17, 2024

Thank you @unscriptable ! I believe you took the right step for curl, as giving more options to developers will allow them to use curl under any circumstance and circumvent some edge cases with some modules.

As for the config property, I vote for: safeLoading: true or saferLoading:true or something that implies the idea of a more foolproof loading process. waitForNextTurn or cascadeAsap are meaningless for someone who is not familiar with curl's internal loading algorithms. But this is just a suggestion. Any identifier will do.

from curl.

dvdotsenko avatar dvdotsenko commented on May 17, 2024

@futuresplash

Re: "saferLoading:true"
That name would be good until another, more advanced even more save way of doing it comes up, where it will be called "superSaferLoading:true" , which will be superseded by "uberSuperSaferLoading:true"

Sometime techie name (that describes exactly what setting does) for a setting is better than "itsBetterForYou: true" :)

from curl.

futuresplash avatar futuresplash commented on May 17, 2024

@dvdotsenko I gess you're right! :-)
I'll keep that in mind for my own projects too.
Although I wouldn't mind having a uberSuperSaferLoading method of loading modules in curl!... ;-)

from curl.

unscriptable avatar unscriptable commented on May 17, 2024

Good points on both sides. I'll bet @dvdotsenko has lots of experience building APIs because that's something that's bit me a few times. It's true what they say: "naming is hard". :)

http://blog.millermedeiros.com/2011/07/naming-methods-properties-and-objects/
http://james.padolsey.com/general/making-apis-is-hard/

I'll try to find a name that infers the end benefit without abstracting the implementation too much.

The more important question in my mind is whether to default to waitForNextTurn: true or waitForNextTurn: false. If we default to false, it could lead to developer frustration. If we default to true, one of curl.js's benefits will be lost on many who never read enough of the documentation.

We'll be adding this parameter to the compatibility sections of the wiki ("Using curl.js with XXX"), which could help in either case.

from curl.

dvdotsenko avatar dvdotsenko commented on May 17, 2024

@unscriptable

The choices you made so far (judging by how fool-proof our use of curl.js was so far) were stellar. Somehow I fee whatever you pick as per your best opinion will come out just right. (I am not sucking up to you. Stating the fact)

from curl.

asilvas avatar asilvas commented on May 17, 2024

I'd be curious as to your reasoning for considering to change the default? Especially if it's for compatibility. Did you run into a bad situation that would warrant the reduced performance?

from curl.

unscriptable avatar unscriptable commented on May 17, 2024

@dvdotsenko thanks!

@asilvas this issue rose out of underscore's initial attempt at AMD compatibility. See issue #36.

There are a few reasons I would consider changing the default: 1) if Chrome is indicative of browsers of the future, the performance difference may be negligible in a few years; 2) in optimized/concatenated files, there is no performance difference; 3) next-turn semantics are increasingly considered "best practices" in server environments.

from curl.

unscriptable avatar unscriptable commented on May 17, 2024

Since the AMDjs fork of underscore fixes the issue, I am removing the milestone on this issue for now.

from curl.

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.