• Stars
    star
    610
  • Rank 73,497 (Top 2 %)
  • Language Less
  • License
    MIT License
  • Created about 7 years ago
  • Updated 27 days ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Stack Overflow’s Design System

Stacks

ci status npm version

Stacks is Stack Overflow’s design system. It includes the resources needed to create consistent, predictable interfaces and workflows that conform to Stack Overflow’s principles, design language, and best practices.

Our documentation is built with Stacks itself, using its immutable, atomic classes and components.

The Stacks website documents:

Product

  • Semantic and accessible component markup
  • Cross-browser compatible Less / CSS
  • An icon library

Email

  • Email templates & components

Stacks documentation can be found at https://stackoverflow.design/

Table of contents

Using Stacks

Using Stacks is outlined in our usage guidelines.

Building Stacks

To contribute to Stacks documentation or its CSS library, you’ll need to build Stacks locally. View our building guidelines.

Having trouble getting these steps to work? Open an issue with a setup label.

Format Stacks

Format the source code with prettier via running:

npm run format

Linting Stacks

Run all lint suites by running:

npm run lint

Lint the styles (stylelint) by running:

npm run lint:css

Lint the typescript source code (eslint) via running:

npm run lint:ts

Lint the source code format (prettier) via running:

npm run lint:format

Testing Stacks

Run all test suites by running:

npm test

Unit/Component Tests

Unit/Component tests are written with DOM Testing Library. Please follow the library's principles and documentation to write tests.

Stacks uses Web Test Runner and Playwright to run tests in a real browser context.

Execute the unit/component tests suite by running:

npm run test:unit

or if you prefer watch mode run:

npm run test:unit:watch

Visual Regression Tests

Prerequisite: In order to pull and upload baseline images you need to have git lfs installed in your local machine. Please follow this guide to install that.

This Web Test Runner plugin is used to run visual regression tests. DOM Testing Library. Visual regression tests end with this suffix *.visual.test.ts.

Execute the visual regression tests suite by running:

npm run test:visual

Update the visual baseline via:

npm run test:visual:update

Failing tests (including diffs) can be found under screenshots/[browser]/failed/ folders.

Releasing a new version of Stacks

Stacks uses Semantic Versioning, is distributed via npm, and publishes release notes on Github. Follow the steps below to release a new version of Stacks.

Bump the version number

npm version [major | minor | patch]

Push the new tag

git push && git push --tags

Create release notes on Github

  1. Visit https://github.com/StackExchange/Stacks/releases/new
  2. Choose your new version from the "Choose a tag" dropdown
  3. Click "Generate release notes"
  4. Cleanup and complete the release notes
    • Prominently mention any breaking changes, if applicable
    • Include a "What's Changed" section in the release notes
    • Mention significant bug fixes
    • Mention new features
    • Mention significant under-the-hood changes that could impact consumers

Ship your newly created version to npm

npm publish

Merge develop into production and push

git checkout production && git merge develop && git push

Push the updated docs site

Head to Netlify, navigate to the Stacks overview, click on "Production deploys", and select "Deploy site" from the "Trigger deploy" dropdown.

Bugs and feature requests

Have a bug or feature request? First search existing or closed issues to make sure the issue hasn’t been noted yet. If not, review our issue guidelines for submitting a bug report or feature request.

Contributing

If you’d like to contribute to Stacks, please read through our contribution guidelines. Included are directions for opening issues, coding standards, and notes on development.

License

Code and documentation copyright 2017-2022 Stack Exchange, Inc and released under the MIT License.

More Repositories

1

blackbox

Safely store secrets in Git/Mercurial/Subversion
Go
6,670
star
2

StackExchange.Redis

General purpose redis client
C#
5,889
star
3

dnscontrol

Infrastructure as code for DNS!
Go
3,043
star
4

NetGain

A high performance websocket server library powering Stack Overflow.
C#
933
star
5

wmi

WMI for Go
Go
433
star
6

pagedown

The Markdown editor and converter used on Stack Overflow and the other Stack Exchange sites
JavaScript
419
star
7

Stacks-Editor

Stack Overflow's Combination Rich Text / Markdown Editor
TypeScript
362
star
8

StackExchange.DataExplorer

Stack Exchange Data Explorer
JavaScript
353
star
9

MarkdownSharp

Open source C# implementation of Markdown processor, used by Stack Overflow.
C#
246
star
10

stack-blog

Stack Overflow Blog
HTML
238
star
11

StackExchange.Utils

Utility class packages used at Stack Exchange...but on NuGet!
C#
195
star
12

httpunit

httpUnit tests compliance of web and net servers with desired output.
Go
164
star
13

StackExchange.Precompilation

Roslyn based csc.exe and aspnet_compiler.exe replacement with metaprogramming hooks for ASP.NET MVC projects from the pre-DNX era
C#
154
star
14

StackExchange.Metrics

A .NET client to send metrics to a variety of metrics backends
C#
136
star
15

Stacks-Icons

Authoring tools for Stack Overflow's shared icon set.
TypeScript
35
star
16

NRediSearch

C#
31
star
17

stackegg

The core game logic of Stack Overflow's April 1st 2015 game, StackEgg.
C#
30
star
18

mayflower

A simple MS SQL Server database migrator using Node.js and TDS.
JavaScript
26
star
19

StackID

An OpenID provider implemented for the Stack Exchange network, built on top of dotNetOpenAuth.
C#
20
star
20

stackexchange.github.com

Source for stackexchange.github.com
HTML
19
star
21

apca-check

Axe rules to check against APCA bronze and silver+ conformance levels.
TypeScript
18
star
22

unikong

Stack Overflow's April 1, 2016 game
JavaScript
16
star
23

haproxy-kubefigurator

Dynamic haproxy configuration for Kubernetes services
Go
14
star
24

RyuJIT-TailCallBug

Tail Call Parameter Corruption Repro for .Net 4.6
C#
12
star
25

signalfx-powershell

This is a PowerShell wrapper around the SignalFx API
PowerShell
10
star
26

mof

Package mof parses and marshals Managed Object Format (MOF) structures
Go
9
star
27

pat

A wrapper for "puppet agent --test"
Go
9
star
28

stackexchange-superfirewall

A facade for firewall::firewall{} that adds enhanced functionality.
Puppet
7
star
29

browserslist-viewer

Static site to parse and display a browserslist string
TypeScript
6
star
30

stacks-utils

A monorepo containing a collection of Stacks config files and other utilities
JavaScript
6
star
31

Stacks-TagHelpers

A set of .Net Core Tag Helpers for use with Stacks
C#
5
star
32

DesignSprint

This repository was used for building a Stack Overflow Talent exploratory design sprint.
HTML
2
star
33

terraform-provider-stackoverflow

Terraform Provider for Stack Overflow
Go
2
star
34

sre-log-1

1
star
35

marketing-resources

1
star