It's an optimization. Useful for rare bits of code, but not so useful for common things like converting an int array to string array. The common things become muscle memory and are removed from the file.
CTRL+F to search. Most of it is self-documenting, in the form of functions or methods that I can just copy into a project.
I don't think any cloud based tools are useful for this because they're too slow with login and search.
For local weekend projects I'm not embarrassed to say that I sometimes just include the whole file. It saves me a lot of time and helps me work on the thing I intend to work on instead of searching the net or wasting time on thinking what implementation is the best.
I might try the "everything.php" or "everything.js" file, scrolling through a single page makes a lot of sense for me as well. But I find I just reference the actual repository in github for backend things, so I can see the context of the use case.
Do you dump "everything.js" and "everything.php" in its own repo in dropbox? Would save the hassle of needing to commit it everytime, pull it from seperate PC's, etc.
I'm still looking for a golden unicorn solution where I just look in one place while still offering micro-testing environments (like codepen). I've tried way too many code snippet solutions it just adds more friction to development
Common snippets I have it all binded by macros.
My goal is to have everything searchable in 3 steps max, one keyboard click, one file navigation button press, and grokking it to find the snippet.
It really doesn't even take me 3 steps to find it anymore since I name the functions quite intuitively (str_match_brackets_balanced) so anytime i type strbrackbal phpstorm automatically autocompletes the function for me. Similar for JS though I haven't been able to create any categories and everything.js is all that is.
I'd love to be able to reorganize that into three subfolders: one for .linq linq queries, one for .cs files instead of .linq files, and another for the mock data. Would be great if I could have all of my c# snippets in .cs files and play with them in VS Code, but I can only run the files in VS Code if I'm working with .NET Core.
I've got a similar but far smaller collection for python snippets and experiments (i.e., playing with an API).
Personally, I have "snippets.org" file in my "wiki/" subfolder on Dropbox.
I find the idea of a personal library of code snippets quite weird. The thought never crossed my mind and I know nobody who uses something like that.
In addition to the code itself, canSnippet also support tags and a description for your snippet.
I'd definitely be interested in peeking at/copying other snippets too.
It contains most of my brain, I wish I started this when I was younger.
rem "this code does nothing"
let i=1
for i=0
beep
else end
alternate functionalities may written as a "remark" and copypasted or edited to make it a compiling line of code so that you can quickly edit the source code and not have to type so much, or go looking through a codesnippit database to find the tool you need...
the actual source code script , depends of course on what language you are using, i chose a pseudo BASIC bcz , well its basic...