globus / globus/globus-sdk-javascript
Logging does not seem to work in browser
- Dominant language
- TypeScript
- Stars
- 11
- Forks
- 4
- Avg merge
- 1d 21h
- Merged PRs (30d)
- 10
Description
### How are you using the `@globus/sdk`?
Client-side JavaScript (e.g. Browser)
### Current and expected behavior
I initialise the logger as follows, in a React single page app :
```
import { authorization, logger } from "@globus/sdk";
logger.setLogger(console)
logger.setLogLevel('debug')
```
It has no effect, i.e. no log message appear in the browser console, despite multiple calls to the API.
Lookin at the code (authenticationManager, etc, I see plenty of logging messages, ex: log('debug', 'AuthorizationManager.handleCodeRedirect') that I should be seeing in the console.
### Environment
System:
OS: Linux 6.8 Ubuntu 24.04.2 LTS 24.04.2 LTS (Noble Numbat)
Shell: 5.2.21 - /bin/bash
Binaries:
Node: 18.16.1 - ~/.nvm/versions/node/v18.16.1/bin/node
npm: 9.5.1 - ~/.nvm/versions/node/v18.16.1/bin/npm
pnpm: 9.12.1 - ~/.nvm/versions/node/v18.16.1/bin/pnpm
### Possible solution
_No response_
### Additional context
_No response_
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.