evert0n / koa-cors

CORS middleware for Koa
MIT License
243 stars 48 forks source link

Support koa@2 #41

Open vhpoet opened 7 years ago

vhpoet commented 7 years ago

Are you planning to support koa@2?

koa deprecated Support for generators will been removed in v3. See the documentation for examples of how to convert old middleware https://github.com/koajs/koa/tree/v2.x#old-signature-middleware-v1x
kunyan commented 7 years ago

@vhpoet https://github.com/kunyan/koa-cors/tree/next

vhpoet commented 7 years ago

@kunyan are you planning on making a PR?

kunyan commented 7 years ago

@vhpoet I can't push a new branch to upstream :(

shellscape commented 7 years ago

@kunyan can you publish this as a module, perhaps koa-cors-next ?

kunyan commented 7 years ago

@evert0n can you checkout a new branch named "next". and I will create a PR to it. then you can publish a new package to npm. the user could use npm install koa-cors@next to download it

I think this way will be better.

evert0n commented 7 years ago

I check it out this weekend guys, I will also catch up with the other issues too, Thank you

crunchtime-ali commented 7 years ago

Just in time for the arrival of native async..await in Node v7.

shellscape commented 7 years ago

exactly. one more thing we don't have to have babel transpile

leebenson commented 7 years ago

@evert0n - any update to this? thanks!

csakbalint commented 7 years ago

@evert0n - hey, is there any possible update to this?

kunyan commented 7 years ago

pls use this until @evert0n push new patch

"koa-cors": "git+https://git@github.com/kunyan/koa-cors.git#next",
leebenson commented 7 years ago

@evert0n, could you push the new patch when you get a spare few mins please? @kunyan's instructions for loading @next are working well, but it'd be good to have an official NPM release.

steffen commented 7 years ago

What's needed to get @kunyan's changes into an official release? Would be nice to get rid of the deprec warning. :) Thanks!

doliver3 commented 7 years ago

It would be great to get @kunyan's change published to npm as koa-cors@next. What is the next step?

meaku commented 7 years ago

@kunyan @evert0n how about a pull request with @kunyan's changes?

jsonmaur commented 7 years ago

Until this gets merged, you can use https://github.com/th507/koa-adapter to get rid of the deprecation warning.

zouxuoz commented 7 years ago

Guys, you can use CORS from main organization https://github.com/koajs/cors.

amit777 commented 7 years ago

hi @evert0n I was wondering if you were planning on merging the pull request from @kunyan. Thank you both for creating this!

bradleyayers commented 7 years ago

Hi @evert0n would you be open to having someone else help maintain this library?

shellscape commented 7 years ago

@bradleyayers why not just use the module maintained by the project? https://github.com/koajs/cors

amit777 commented 7 years ago

@shellscape that's a great q.. I can't remember why I didn't personally use it, but I vaguely remember being some reason. I should probably take a second look at it. thanks for the tip.