GithubHelp home page GithubHelp logo

nukosuke / annict.js Goto Github PK

View Code? Open in Web Editor NEW
14.0 4.0 0.0 524 KB

:dvd: Annict API client library for JavaScript ( & TypeScript) :tv:

Home Page: https://nukosuke.github.io/annict.js/

License: MIT License

TypeScript 58.40% JavaScript 41.60%
annict javascript typescript

annict.js's People

Contributors

greenkeeperio-bot avatar nukosuke avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

annict.js's Issues

recreate npm token

前のバージョンリリースしたのが相当前なのでいざこざでおそらくexpireされてるはず。

再度生成してauto deployできるようにしておく。

It’s been a while since last release. Current token maybe expired for the past npm incident.
It must be regenerated.

APIのURIの引数が冗長

デコレータでこんな感じに書きたい。

@BaseURI('https://api.annict.com')
class Annict {

    @Endpoint('/v1/me/records/:id')
    update(...) {
    ...
    }

}

NodeでAuthorizationService.token()メソッドを呼び出すとエラーが発生する

https://gyazo.com/b39eb9f59ed10fd1d2464304597ba0b3

webpack.config.jsで定義してるBROWSER定数を

if (BROWSER) {
  ...
}

として分岐してるのがまずい。

if (typeof BROWSER !== 'undefined') {
  ...
}

で解決できそう。
あと、環境ごとの分岐テスト書いた方が良さげ。

    it('client works on Node environment', done => {
        expect(typeof BROWSER).to.eql('undefined');
        done();
    });

Cross Origin Error

#25 (comment)

Annictの仕様なのでannictリポジトリにissueを立てる。
対応されたら #25 をマージしてv0.0.4リリース。
なんらかの理由で返答が対応不可ならブラウザサポートを切ってv0.0.4マイルストーンをclose。

implement client.setToken()

annict.client.setToken("<ANNICT_TOKEN>");

equivalent to

const token = "<ANNICT_TOKEN>";
annict.client.setHeader("Authorization", "Bearer `${token}`");

テスト

  • mocha
  • chai
  • nock
  • travis

のコンボで

document

TODO

  • /oauth/
  • /v1/works
  • /v1/episodes
  • /v1/records
  • /v1/me/statuses
  • /v1/me/records
  • /v1/me/works
  • /v1/me/programs

validation of Object args

currently: it has to be nofified by response error
change to: validate arg Object before sending request

I want mini validation library.

Action required: Greenkeeper could not be activated 🚨

🚨 You need to enable Continuous Integration on all branches of this repository. 🚨

To enable Greenkeeper, you need to make sure that a commit status is reported on all branches. This is required by Greenkeeper because it uses your CI build statuses to figure out when to notify you about breaking changes.

Since we didn’t receive a CI status on the greenkeeper/initial branch, it’s possible that you don’t have CI set up yet. We recommend using Travis CI, but Greenkeeper will work with every other CI service as well.

If you have already set up a CI for this repository, you might need to check how it’s configured. Make sure it is set to run on all new branches. If you don’t want it to run on absolutely every branch, you can whitelist branches starting with greenkeeper/.

Once you have installed and configured CI on this repository correctly, you’ll need to re-trigger Greenkeeper’s initial pull request. To do this, please delete the greenkeeper/initial branch in this repository, and then remove and re-add this repository to the Greenkeeper App’s white list on Github. You'll find this list on your repo or organization’s settings page, under Installed GitHub Apps.

TS3

いい加減対応しとく。
ついでに #84 のfailもなおす。

Support TypeScript 3.x and fix CI failure of #84.

Quit bower support

Probably, few people use bower now. It is not necessary to support any more.

new endpoints

https://t.co/xeKTYHjd8u #75

new endpoints

  • /v1/activities
  • /v1/following
  • /v1/followers
  • /v1/users
  • /v1/me
  • /v1/me/following_activities

new fields

  • record_comments_count (/v1/episodes)
  • avatar_url, background_image_url (/v1/users)
  • status.kind (/v1/me/works)
  • filter_has_record_comment (/v1/records)

npm install warning

npm WARN deprecated @types/[email protected]: This is a stub types definition for es6-promise (https://github.com/jakearchibald/ES6-Promise). es6-promise provides its own type definitions, so you don't need @types/es6-promise installed!

remove @types/es6-promise from package.json

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.