
Security News
Deno 2.2 Improves Dependency Management and Expands Node.js Compatibility
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Make freeze-dried web searches using text mind-maps.
npm i eyedact
Eyedact is an alternative means to Google using typed mindmaps covering a complex domain.
Nothing.
Alt+Tab to your browser, Ctrl+L, type and hit Enter. If you know what you are looking for, you don't need Eyedact. This is for people who are figuring out how to navigate a specific knowledge domain.
Eyedact targets autodidacts that want to find out what they need to know to work on something, especially when they aren't sure what to look for. Eyedact lets you write searches that are too vague for Google and still get results in the context for their subject. Hence "freeze-dried" web searches.
In the example below, you will see notes acting as a source of searches that one would not need after becoming sufficiently familiar with Mongo.
I write loose mindmaps in text files to avoid fussing with GUIs and proprietary file formats. The structure is simple: indent concepts when they belong to the concept on a previous line.
Given the offensively incomplete text file ~/notes/mongo
for a
new student of document stores:
Mongo
databases
collections
documents
key-value pairs
ids are 12 byte hex values called _id
cursors
aggregation pipeline
map-reduce
stages
best practices
join on write, not read
optimize for most frequent use cases
sharding for horizontally scaling
benefits
any field is indexable
easy to replicate and scale
commands
use
show
createcollection
show collections
insert()
find()
limit()
pretty()
remove()
save()
skip()
sort()
update()
For the sake of explicit manual prep, put this in ~/.bashrc
:
alias s?='eyedact ~/notes/mongo`
Now you can do this:
$ s? reduce --lucky # Search Google+I'm Feeling Lucky for "Mongo aggregation pipeline map-reduce"
$ s? practices # Search Google (not feeling lucky) for "Mongo best practices"
$ s? collection show --all # Open one tab for each match (without --all, use only first match)
Eyedact checks if the string you enter appears in any of the lines of the mindmap to find a match. You do not have to know what's in a mindmap before searching, you only need to recall some term.
Even if you run a query would still work fine if typed into Google directly, it's nice to have a shorter search query fire up your browser with the pages you need already up. That is, it's nice if you are a terminal junkie that can't be bothered with windows.
$ eyedact MINDMAPFILE needle [needle [needle [...]] [--lucky] [--all]
MINDMAPFILE
: Path to text file containing concepts indented to show
relationships between ideas in a knowledge domain. If set to -
, eyedact
will read from STDIN.needle
: At least one string to match against lines in the mindmap.
If the needle appears inside a line, its a match.--lucky
/-l
: Use Google's "I'm Feeling Lucky" feature.--all
/-a
: Search for every match, not just the first.# Open React and Redux tutorials
$ curl https://pastebin.com/raw/qNWujKhc | eyedact - tutorial -al
Eyedact also helps as a way to document what you expect other people to know, without writing much yourself. You can place a map showing what you need contributors to know to work on your project.
GraphQL
Apollo assumptions (see Dhaivat Pandya speech)
Same path, same object
Same ID, same object
caching
best practices
server
client
schemas
queries
selection sets
go within queries
define edges to traverse from some matching set
Docker
image
container
build
Webpack
build
externals
Restify
caching
gzip
routes
Redux
single application state
state objects are immutable
best practices
actions
only way to tell app to change state
don't confuse "change what app uses as state" with "change state object"
async
React
rendering
component
Higher-order
ES6 vs ES5
best practices
Top-heavy state
async
This mindmap communicates that your app uses GraphQL, React, Redux, Webpack, Restify, Docker, plus relevant facts that you want people to understand under each technology.
Then in package.json
you can use the CLI
{
...
"scripts": {
"stackdoc": "eyedact what-you-should-know"
}
}
# Search for all caching, async topics (GraphQL+Restify+React+Redux)
$ npm run stackdoc caching async -a
# List first match for container (Docker)
$ npm run stackdoc caching -l
This is a quick alternative to writing long documents with manually inserted links to other manuals. All web searches will be in the context of what you need people to know.
Use STDIN if you want to use a shared mindmap across multiple projects, such as from PasteBin as shown above.
const eyedact = require('eyedact');
const readablestream = eyedact({
haystack: '/path/to/mindmap',
needles: ['searchstring'],
// Search for all matches if true, otherwise only the first match.
openall: false,
// If true, use "I'm Feeling Lucky"
lucky: true,
});
FAQs
Freeze-dried searches from text mind maps
The npm package eyedact receives a total of 1 weekly downloads. As such, eyedact popularity was classified as not popular.
We found that eyedact demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Deno 2.2 enhances Node.js compatibility, improves dependency management, adds OpenTelemetry support, and expands linting and task automation for developers.
Security News
React's CRA deprecation announcement sparked community criticism over framework recommendations, leading to quick updates acknowledging build tools like Vite as valid alternatives.
Security News
Ransomware payment rates hit an all-time low in 2024 as law enforcement crackdowns, stronger defenses, and shifting policies make attacks riskier and less profitable.