ogio

0.4.0 • Public • Published
OG I/O logo

npm license


wut?

"The most dangerous js library I know"
– Data Science OG

OG I/O... what it's all 'bout?

Install

npm i ogio
require("ogio")

Fetch!

"file.txt".g()
// => This is a text
await "@file.txt".g()
// => This is the same text, but async
"file.json".g()
// => {txt: "Parsed json"}
await "https://example.com".g()
// => <html> ... </html>
await "https://example.com/file.json".g()
// => {txt: "Parsed json from example.com"}

Save!

"file.txt".s("This will be a text")
// => This will be a text
await "@file.txt".s("The same text, but async")
// => The same text, but async
"file.json".s({txt:"json smth"})
// => {
//        "txt": "json smth"
//    }

...More stuff is coming

Package Sidebar

Install

npm i ogio

Weekly Downloads

2

Version

0.4.0

License

MIT

Unpacked Size

6.1 kB

Total Files

4

Last publish

Collaborators

  • c451