Open usrbowe opened 2 years ago
I would like to discuss more about more flexibility in configuring those fields, when using js-flipper:
js-flipper
[ ] os - currently relies on detectOS util, which might not cover all use cases https://github.com/facebook/flipper/blob/6dc85f6646ba5951cb9e87d085ceb13140673870/js/js-flipper/src/util.ts#L51-L63
os
detectOS
[ ] device - uses detectDevice util. Currently also default to undefined as string in clientQuery if unsupported device is used. https://github.com/facebook/flipper/blob/6dc85f6646ba5951cb9e87d085ceb13140673870/js/js-flipper/src/util.ts#L65-L70
device
detectDevice
undefined
clientQuery
This could be done as extra param in flipperClient.start(...): https://github.com/facebook/flipper/blob/6dc85f6646ba5951cb9e87d085ceb13140673870/js/js-flipper/src/client.ts#L150-L151
flipperClient.start(...)
clientQuery.app
Currently uses the device and client as same name. https://github.com/facebook/flipper/blob/6dc85f6646ba5951cb9e87d085ceb13140673870/desktop/flipper-server-core/src/comms/ServerController.tsx#L258-L264
client
icon
Currently all js-flipper connection will not have any icon, since it's not specified. We could allow to pass extra clientQuery to provide icon name. Likely could have default for Browser and NodeJS in similar fashion as detectOS util. https://github.com/facebook/flipper/blob/6dc85f6646ba5951cb9e87d085ceb13140673870/js/js-flipper/src/client.ts#L230
We could go from this state:
To this state:
Love the improvements! I'd be happy to accept PRs for each one of them
Ok, let me compile the changes in PR.
Current state
I would like to discuss more about more flexibility in configuring those fields, when using
js-flipper
:[ ]
os
- currently relies ondetectOS
util, which might not cover all use cases https://github.com/facebook/flipper/blob/6dc85f6646ba5951cb9e87d085ceb13140673870/js/js-flipper/src/util.ts#L51-L63[ ]
device
- usesdetectDevice
util. Currently also default toundefined
as string inclientQuery
if unsupported device is used. https://github.com/facebook/flipper/blob/6dc85f6646ba5951cb9e87d085ceb13140673870/js/js-flipper/src/util.ts#L65-L70Proposal
Specify manually
os
,device
This could be done as extra param in
flipperClient.start(...)
: https://github.com/facebook/flipper/blob/6dc85f6646ba5951cb9e87d085ceb13140673870/js/js-flipper/src/client.ts#L150-L151Use
device
instead of applyingclientQuery.app
Currently uses the
device
andclient
as same name. https://github.com/facebook/flipper/blob/6dc85f6646ba5951cb9e87d085ceb13140673870/desktop/flipper-server-core/src/comms/ServerController.tsx#L258-L264Allow specify
icon
for appCurrently all
js-flipper
connection will not have any icon, since it's not specified. We could allow to pass extraclientQuery
to provide icon name. Likely could have default for Browser and NodeJS in similar fashion asdetectOS
util. https://github.com/facebook/flipper/blob/6dc85f6646ba5951cb9e87d085ceb13140673870/js/js-flipper/src/client.ts#L230Visual comparison
We could go from this state:
To this state: