CodeCook.io contains many code snippets for performing common task when creating software, websites and performing system administrative tasks. Our goal is to present simple task oriented code snippets with all the necessary meta information such as platform requirements and dependencies. We want you to quickly find the canonical method to solve a problem and easily asses both the benefits and drawbacks of each approach. Snippets can be static pieces of code but can also incorporate customizable parameters (resembling macros).
If you want to make your own snippets, improve someone else's or want access to the API then please create an account. Registration is a breeze.
"Who creates the content?" You do, well at the moment registration is still invitational only, but the idea is that the community will create concepts, methods and snippets.
We strive for creating a list of snippets for a wide range of languages, frameworks, libraries and more. In essence we are creating a meta language/framework around a enormous set of possibilities. We try to create a powerful language/framework that benefits from specializing in code snippets. While still being general enough to encompass a wide range of languages, frameworks and tools. It's a delicate and difficult balance between specificity and generality. Our dilemma is brilliantly summarized in the quote:
All problems in computer science can be solved by another level of indirection... Except for the problem of too many layers of indirection.
"Can i use this code in my own work?" Yes, that is the idea. Look at our (permissive) license for more information.
Besides improving current features we have quite ideas to implement in the future. Here are some of our ideas in our backlog in no particular order.
- Open registration for everybody.
- Method version compatibility, e.g.: Works for "ansi-c", "Firefox>14", "8<IE<=10", "Chrome>13 and jQuery>1.6".
- Complex parameter model. Indicating the type of a parameter and acceptable values.
- Edit suggestion and peer reviewing.
- Method time/memory complexity
- Package/library/module dependency. Indicate dependencies for a piece of code again with version information.
- Faceted search.
- Basic plugins for many popular editors and terminals/shells.
Please contact us if want to suggest and improvement. Also let us know if you would like to indicate what you think should have priority. We definitely prefer working on features that you as a user would like to see.