Giter Site home page Giter Site logo

jonathanlyon / prettygoodstreetviewer Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 13 KB

This project implements a Google Street View Panorama that can be initialized with specific coordinates and heading using URL parameters. It's built using TypeScript and the Google Maps JavaScript API.

HTML 26.76% TypeScript 64.01% CSS 5.08% JavaScript 4.15%

prettygoodstreetviewer's Introduction

PrettyGood Logo

About PrettyGood

PrettyGood is a purpose-driven brand and media agency dedicated to building brands for good. We believe in the power of positive impact and strive to create meaningful change through our work.

Visit our website: www.prettygood.nz

This project is part of our ongoing efforts to create innovative solutions that make a difference.

PrettyGood Google Street View Panorama with URL Parameters

Project Overview

This project implements a Google Street View Panorama that can be initialized with specific coordinates and heading using URL parameters. It's built using TypeScript and the Google Maps JavaScript API.

Features

  • Display a Google Street View Panorama on a web page
  • Set initial latitude, longitude, and heading via URL parameters
  • Fallback to default values if URL parameters are not provided

Installation

  1. Clone this repository:

    git clone [Your Repository URL]
    
  2. Navigate to the project directory:

    cd [Your Project Directory]
    
  3. Install dependencies (assuming you're using npm):

    npm install
    
  4. Set up your Google Maps API key:

    • Obtain an API key from the Google Cloud Console
    • Add your API key to the project (the exact method depends on your setup)

Usage

  1. Start the development server:

    npm run dev
    
  2. Open your browser and navigate to http://localhost:5173/ (or whatever port your dev server uses)

  3. To set the initial view, use URL parameters:

    • urllat: Latitude (float)
    • urllng: Longitude (float)
    • urlhead: Heading (float, in degrees)

    Example:

    http://www.yoursite.com/?urllat=-36.8645111&urllng=174.7459659&urlhead=180
    

Default Values

If URL parameters are not provided, the following default values are used:

  • Latitude: -36.8645111
  • Longitude: 174.7459659
  • Heading: 0

Contributing

Contributions are welcome! Please feel free to submit a Pull Request.

License

This project is licensed under the Apache 2.0 License - see the LICENSE file for details.

Acknowledgments

  • Google Maps Platform for providing the Street View API
  • PrettyGood team for their support and inspiration

Author

This project was developed by Jonathan Lyon, Co-Founder and Chief Product Officer at PrettyGood.


prettygoodstreetviewer's People

Contributors

jonathanlyon avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.