{"id":15542035,"url":"https://github.com/lifeart/ember-jsonp","last_synced_at":"2025-07-27T09:12:59.859Z","repository":{"id":57223945,"uuid":"89107734","full_name":"lifeart/ember-jsonp","owner":"lifeart","description":"Ember JSONP loader","archived":false,"fork":false,"pushed_at":"2018-07-07T18:54:17.000Z","size":208,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-07-14T15:18:50.408Z","etag":null,"topics":["addon","ember-addon","ember-jsonp","jsonp"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lifeart.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-04-23T00:34:25.000Z","updated_at":"2020-08-18T14:10:12.000Z","dependencies_parsed_at":"2022-08-30T02:40:28.547Z","dependency_job_id":null,"html_url":"https://github.com/lifeart/ember-jsonp","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/lifeart/ember-jsonp","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lifeart%2Fember-jsonp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lifeart%2Fember-jsonp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lifeart%2Fember-jsonp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lifeart%2Fember-jsonp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lifeart","download_url":"https://codeload.github.com/lifeart/ember-jsonp/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lifeart%2Fember-jsonp/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267335520,"owners_count":24070777,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-07-27T02:00:11.917Z","response_time":82,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["addon","ember-addon","ember-jsonp","jsonp"],"created_at":"2024-10-02T12:20:29.607Z","updated_at":"2025-07-27T09:12:59.793Z","avatar_url":"https://github.com/lifeart.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ember-jsonp\n\n[Short description of the addon.]\n\nThis is service addon, named `jsonp`, providing `ember-ajax` -like UX with JSONP data without jQuery\n\n\n## DEMO\n\n [https://lifeart.github.io/ember-jsonp/demo/](https://lifeart.github.io/ember-jsonp/demo/)\n\n\n## Usage Example\n\n\n```\n  ember install ember-jsonp\n\n```\n\n```\n\n   this.get('jsonp').request(URL,context,success,error,options);\n   \n   \u003c\u003cOR\u003e\u003e\n   \n   this.get('jsonp').request(URL,options).then(success).catch(error);\n    \n   \u003c\u003cOR\u003e\u003e\n\n   this.get('jsonp').request({url,paramName}).then(success).catch(error);\n   \n   \u003c\u003cOR\u003e\u003e\n   \n    this.get('jsonp').request({\n      url: \"http://site.com?method=jsonp\u0026callback={{callbackName}}\",\n      pattern: \"{{callbackName}}\"\n    }).then(success).catch(error);\n   \n```\n\n\n```\n  jsonp: service(),\n  init() {\n    this.set('searchTag', 'emberconf');\n  },\n  items: computed(function () {\n    return [];\n  }),\n  searchTag: '',\n  getFlickerURI() {\n    let encodedTag = encodeURIComponent(this.get('searchTag'));\n    return `//api.flickr.com/services/feeds/photos_public.gne?tags=${encodedTag}\u0026format=json`;\n  },\n  searchTagDidChange: on('init', observer('searchTag', function() {\n    let url = this.getFlickerURI();\n    this.get('jsonp').request(url,this,(result)=\u003e{\n      this.set('items',result.items);\n    },(error)=\u003e{\n      console.log(error);\n    },{\n      paramName: 'jsoncallback'\n    });\n\n  }))\n\n```\n\n`ember-jsonp` generates random JSONP callback, with timeout and success/error handlers;\n\n\n## Options \n\n* `paramName` callback parameter name\n* `callbackName` callback name\n* `timeout` timeout (ms)\n* `uri` or `url` request URL\n* `context` context for success/error handlers\n* `success` success handler\n* `error` error handler\n* `pattern` callbackName pattern,\n\nallows URL like  http://site.com/jsonp?callback={{callbackName}}\n\nwhere `{{callbackName}}` -\u003e pattern for replacing by service\n\n## Installation\n\n```\nember install my-addon\n```\n\n\nUsage\n------------------------------------------------------------------------------\n\n[Longer description of how to use the addon in apps.]\n\n\nContributing\n------------------------------------------------------------------------------\n\n### Installation\n\n* `git clone \u003crepository-url\u003e`\n* `cd my-addon`\n* `npm install`\n\n### Linting\n\n* `npm run lint:js`\n* `npm run lint:js -- --fix`\n\n### Running tests\n\n* `ember test` – Runs the test suite on the current Ember version\n* `ember test --server` – Runs the test suite in \"watch mode\"\n* `ember try:each` – Runs the test suite against multiple Ember versions\n\n### Running the dummy application\n\n* `ember serve`\n* Visit the dummy application at [http://localhost:4200](http://localhost:4200).\n\nFor more information on using ember-cli, visit [https://ember-cli.com/](https://ember-cli.com/).\n\nLicense\n------------------------------------------------------------------------------\n\nThis project is licensed under the [MIT License](LICENSE.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flifeart%2Fember-jsonp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flifeart%2Fember-jsonp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flifeart%2Fember-jsonp/lists"}