googleworkspace / apps-script-oauth2

An OAuth2 library for Google Apps Script.
https://developers.google.com/apps-script/
Apache License 2.0
1.56k stars 429 forks source link

Adds entrypoint #398

Closed spacenate closed 2 years ago

spacenate commented 2 years ago

As a developer building a GAS project using ES modules (import/export), I would like to be able to import this package:

import { OAuth2 } from 'OAuth2';

Currently, this fails with an error like so:

Module not found: Error: Can't resolve 'OAuth2' in '/Users/nathan/.../src'

Field 'browser' doesn't contain a valid alias configuration

After declaring an entry-point for this package (via package.json), then I am able to import the package without error.

google-cla[bot] commented 2 years ago

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.