diff --git a/.github/workflows/deploy-website.yml b/.github/workflows/deploy-website.yml new file mode 100644 index 00000000..d68732c7 --- /dev/null +++ b/.github/workflows/deploy-website.yml @@ -0,0 +1,61 @@ +name: Deploy to Pages + +on: + # Runs on pushes targeting the default branch + push: + branches: ['main'] + + # Allows you to run this workflow manually from the Actions tab + workflow_dispatch: + +# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages +permissions: + contents: read + pages: write + id-token: write + +# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued. +# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete. +concurrency: + group: 'pages' + cancel-in-progress: false + +jobs: + build: + name: Build Website + runs-on: ubuntu-latest + steps: + - name: Checkout + uses: actions/checkout@v3 + + - name: Setup node + uses: actions/setup-node@v3 + with: + node-version: '18' + cache: npm + + - name: Install dependencies + run: npm ci + working-directory: ./website + + - name: Build website + run: | + npm run build + working-directory: ./website + + - name: Upload artifact + uses: actions/upload-pages-artifact@v2 + with: + path: ./website/build + + # Deployment job + deploy: + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} + runs-on: ubuntu-latest + needs: build + steps: + - name: Deploy to GitHub Pages + id: deployment + uses: actions/deploy-pages@v2 diff --git a/README.md b/README.md index f4820733..3026dc38 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@ -# Google Maps React +# React Comnponents for the Google Maps API -[![MIT License](https://img.shields.io/badge/license-MIT-green.svg)](https://github.com/ubilabs/google-maps-react-hooks/tree/main/LICENSE) +[![MIT License](https://img.shields.io/badge/license-MIT-green.svg)](https://github.com/visgl/react-google-maps/tree/main/LICENSE) A library to integrate the Google Maps JavaScript API into React Applications using simple components or hooks. diff --git a/src/components/map.tsx b/src/components/map.tsx index 03e5498e..e70f4a0f 100644 --- a/src/components/map.tsx +++ b/src/components/map.tsx @@ -33,7 +33,7 @@ export type MapProps = google.maps.MapOptions & { */ className?: string; /** - * Adds initial bounds to the map + * Adds initial bounds to the map as an alternative to specifying the center/zoom of the map. * Calls the fitBounds method internally https://developers.google.com/maps/documentation/javascript/reference/map?hl=en#Map-Methods */ initialBounds?: google.maps.LatLngBounds | google.maps.LatLngBoundsLiteral;