Skip to content
This repository has been archived by the owner on Jan 31, 2023. It is now read-only.

Latest commit

 

History

History
52 lines (34 loc) · 1.57 KB

CONTRIBUTING.md

File metadata and controls

52 lines (34 loc) · 1.57 KB

Contributing

Local development

Follow these steps to get the website and Chrome extension running on your local machine:

# Clone the repository
git clone https://github.com/primer/octicons-v2.git
cd octicons-v2

# Install the dependencies
yarn

# Start the development server
yarn start

# Navigate to http://localhost:8000 in your browser

Note: These steps require Yarn to be set up locally. See yarnpkg.com for more information.

Loading the Chrome extension

Once you've started the local development server, follow these steps to load the extension into Chrome:

  1. Open Chrome and navigate to chrome://extensions.
  2. Enable Developer mode using the toggle in the top right.
  3. Click "Load unpacked".
  4. Find and select the extension directory from this project.

Note: You'll only need to load the extension once.

Adding an icon

  1. Start the development server:

    yarn start
  2. Place an SVG file in the icons/ directory.

  3. Optimize the SVG:

    yarn svgo

    Tip: Open a new terminal session before running yarn svgo to avoid stopping the developement server.

  4. View your icon at http://localhost:8000.

  5. Reload the Octicons v2 extension in Chrome to see the icon on github.com. You can reload the extension from chrome://extensions but we recommend using the Extension Reloader extension because it allows you to reload unpacked extensions from the toolbar.