Coder Social home page Coder Social logo

Support JSONP responses about jsonview HOT 4 CLOSED

bhollis avatar bhollis commented on August 16, 2024
Support JSONP responses

from jsonview.

Comments (4)

afeld avatar afeld commented on August 16, 2024

Express.js's jsonp() method formats responses in the following way (or see a live example):

callbackName && callbackName({
  // ...
});

Would be nice to have this format recognized as JSONP by JSONView.

from jsonview.

bhollis avatar bhollis commented on August 16, 2024

Makes sense. The regex should be easy to modify, want to send a PR?

-Ben

Sent from my phone

On Apr 3, 2013, at 10:30 AM, Aidan Feldman [email protected] wrote:

Express.js's jsonp() method
http://expressjs.com/api.html#res.jsonpformats responses in the
following way (or see a live
examplehttp://omniembed.herokuapp.com/v1.json?callback=foo&url=http%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3D3Yuqxl284cg
):

callbackName && callbackName({
// ...});

Would be nice to have this format recognized as JSONP by JSONView.


Reply to this email directly or view it on
GitHubhttps://github.com//issues/9#issuecomment-15851148
.

from jsonview.

neoascetic avatar neoascetic commented on August 16, 2024

+1

from jsonview.

bhollis avatar bhollis commented on August 16, 2024

These days I can't say I have any use for JSONP in general - CORS is a much better solution. I'm also not interested in chasing down every variant on a "JSONP" response that a different web server might produce. Furthermore, I can't really see JSONView ever being the viewer responsible for text/javascript or application/javascript content. I'm going to close this feature request and likely remove what JSONP support exists in JSONView for the next release.

from jsonview.

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.