Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

minor nit with docs for create and createWithMemory factories #162

Open
SteveALee opened this issue Jan 1, 2017 · 0 comments
Open

minor nit with docs for create and createWithMemory factories #162

SteveALee opened this issue Jan 1, 2017 · 0 comments

Comments

@SteveALee
Copy link
Contributor

http://staltz.com/xstream/#create
http://staltz.com/xstream/#createWithMemory

Both state "Creates a new Stream given a Producer" implying Producer is required but then say "An optional Producer".

So is it truly optional and what happens if not provided?

the declaration at
https://github.com/staltz/xstream/blob/master/src/index.ts#L1395
says it IS optional and the code explicitly casts an empty object (NO) to an InternalProducer. That is an interface not an implementation but still appears to have some default (void) behaviour if not state.

My TS chops are severely lacking so I'm not sure if this is an correct interpretation or I'm missing something.

Can we please define in the Docs what the default behaviour is without a produce being supplied?

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants