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

Code to interface, not to implementation #24

Open
samdark opened this issue Mar 26, 2015 · 2 comments
Open

Code to interface, not to implementation #24

samdark opened this issue Mar 26, 2015 · 2 comments

Comments

@samdark
Copy link

samdark commented Mar 26, 2015

Currently it's not really possible to provide your own models to store questions, answers or tags. It could be useful, for example, to be able to use markdown or bbcode for writing text there or for deeper integration with the application.

I'd suggest coding to interface i.e.

  1. Introduce a number of interfaces describing module's interaction with models.
  2. Make default set of models implement these interfaces.
  3. Make all other code use these interfaces and not use models directly.
  4. Make it possible to provide your own models implementing interfaces instead of default ones.

See https://github.com/samdark/Yeeki/tree/master/app/modules/wiki/components/auth

@JiLiZART
Copy link
Member

Nice idea. I think about Markdown in next release. I read about use interfaces.

@samdark
Copy link
Author

samdark commented Mar 27, 2015

It's not about markdown, it's about making the module extensible.

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

No branches or pull requests

2 participants