question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Suggestion]: An examples directory would be great

See original GitHub issue

An examples directory which some implementations of common usages would be great.

For example, I was trying to implement get a basic api fetch to give the library a test-ride but I couldn’t get it working. Hopefully, if I ever get a hang of the library, I could contribute examples myself but that is not something I can do right now.

Btw, I wanted to say that the library looks great!

(P.S Since I’m here, could some github tags be added so the library is more discoverable? I couldn’t recall its name once and I couldn’t find it when I was searching for functional monad etc)

Issue Analytics

  • State:open
  • Created 2 years ago
  • Comments:6 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
pandu-supriyonocommented, Jan 24, 2022

Great, in that case I’m on it. Did you already happen to have something in mind with regards to how the examples should look?

I’m thinking something to the likes of:

|
| -- src/
| -- examples/
    | -- package.json
    | -- README.md
    | -- synchronous.ts
    | -- asynchronous.ts
    | -- http-client.ts <-- a more integrated/contextually rich example combining sync and async functions, 
                            as well as some utility functions in a trivial Koa or Express app?

I’ll keep in mind to leave the FP terms behind considering the design philosophy of this lib. In my opinion, the idea of composing safe functions deserves quite some attention and I would emphasize that in the examples.

1reaction
pandu-supriyonocommented, Jan 23, 2022

Late to the party, and I feel like the examples in the API docs are quite good already.

Though I can understand that someone might need more contextually rich examples.

I’ve been playing around with the library and checking out the source and am feeling quite comfortable enough to work on this if you feel this is necessary.

Read more comments on GitHub >

github_iconTop Results From Across the Web

No results found

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found