Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove plugs from Spandex core #81

Open
GregMefford opened this issue Oct 5, 2018 · 6 comments
Open

Remove plugs from Spandex core #81

GregMefford opened this issue Oct 5, 2018 · 6 comments
Milestone

Comments

@GregMefford
Copy link
Member

See the Plug docs for details, but libraries aren't supposed to pollute the assigns on the Conn.

https://github.com/elixir-plug/plug/blob/master/lib/plug/conn.ex#L69
https://github.com/elixir-plug/plug/blob/master/lib/plug/conn.ex#L84-L89

@zachdaniel
Copy link
Member

👍

@zachdaniel
Copy link
Member

Thinking about it, we should probably move the plugs stuff over to spandex_phoenix or something. I know plugs are their own thing, but it probably fits more there than it does here.

@GregMefford
Copy link
Member Author

Yeah I had the same thought, but at the time, we didn't have spandex_phoenix. Now that we do, I'd like to make a use Spandex.Phoenix type macro that will include the plugs automatically, but perhaps still have a way you could include them manually like you can today.

@zachdaniel zachdaniel changed the title Plugs should use private instead of assigns for storing state Remove plugs from Spandex core Nov 26, 2018
@zachdaniel
Copy link
Member

I've updated this issue to represent more modern times. In our 3.0.0 release we should simply remove the plugs from core.

@zachdaniel zachdaniel added this to the 3.0.0 milestone Nov 26, 2018
@GregMefford
Copy link
Member Author

Agreed, which means we should go ahead and deprecate them now, in favor of the spandex_phoenix integration.

@zachdaniel
Copy link
Member

Yeah, great plan. How do you deprecate a plug? Do we just deprecate the call or init function?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants