You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 30, 2021. It is now read-only.
Inside the function initMiddleware there is the following call:
app.enable('jsonp callback');
What is the intent behind this? By the looks of it, it is related to whether or not the app enables jsonp callback support, however I am puzzled as to how/where this is used. Is it deprecated? Or, perhaps, is the express API doc missing this? I ask this question for the following reasons:
this setting doesn't appear to be used/read anywhere else in the app. i.e. a search here in the github repository for the setting jsonp callback returns only a single result, i.e. where it is set. I understand from this that it is probably not intended to be 'used' by the app but rather by the express module internally;
according to the express API doc, app.enable(name) sets the Boolean setting name to true, where name is one of the properties from the app settings table. However, I note that jsonp callback isn't listed in said app settings table.
Thanks for your time reading and considering this question.
Sincerely,
Dan
The text was updated successfully, but these errors were encountered:
@danoz-direct thanks for bringing this up.
I don't think it's required anymore but the option does exist, if you look at the settings table you pointed (http://expressjs.com/en/4x/api.html#app.settings.table) then it's there with a default 'callback' handler if the name is not specified.
Hi everyone,
This is a similar question to #1447
A query regarding a setting in module config/lib/express.js...
Inside the function
initMiddleware
there is the following call:app.enable('jsonp callback');
What is the intent behind this? By the looks of it, it is related to whether or not the app enables jsonp callback support, however I am puzzled as to how/where this is used. Is it deprecated? Or, perhaps, is the express API doc missing this? I ask this question for the following reasons:
jsonp callback
returns only a single result, i.e. where it is set. I understand from this that it is probably not intended to be 'used' by the app but rather by the express module internally;app.enable(name)
sets the Boolean settingname
to true, wherename
is one of the properties from the app settings table. However, I note thatjsonp callback
isn't listed in said app settings table.Thanks for your time reading and considering this question.
Sincerely,
Dan
The text was updated successfully, but these errors were encountered: