{"id":19653051,"url":"https://github.com/csstools/postcss-short-border","last_synced_at":"2025-04-28T17:31:22.221Z","repository":{"id":57328509,"uuid":"43475018","full_name":"csstools/postcss-short-border","owner":"csstools","description":"Define multiple sides on border properties in CSS","archived":false,"fork":false,"pushed_at":"2018-10-10T12:33:42.000Z","size":22,"stargazers_count":6,"open_issues_count":0,"forks_count":2,"subscribers_count":5,"default_branch":"master","last_synced_at":"2024-04-13T20:48:25.810Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://jonathantneal.github.io/postcss-short/","language":"CSS","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"cc0-1.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/csstools.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-10-01T02:44:54.000Z","updated_at":"2023-04-02T05:42:21.000Z","dependencies_parsed_at":"2022-09-21T01:52:14.315Z","dependency_job_id":null,"html_url":"https://github.com/csstools/postcss-short-border","commit_stats":null,"previous_names":["jonathantneal/postcss-short-border"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/csstools%2Fpostcss-short-border","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/csstools%2Fpostcss-short-border/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/csstools%2Fpostcss-short-border/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/csstools%2Fpostcss-short-border/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/csstools","download_url":"https://codeload.github.com/csstools/postcss-short-border/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":224124800,"owners_count":17259746,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-11T15:13:02.238Z","updated_at":"2024-11-11T15:13:03.278Z","avatar_url":"https://github.com/csstools.png","language":"CSS","funding_links":[],"categories":[],"sub_categories":[],"readme":"# PostCSS Short Border [\u003cimg src=\"https://postcss.github.io/postcss/logo.svg\" alt=\"PostCSS\" width=\"90\" height=\"90\" align=\"right\"\u003e][postcss]\n\n[![NPM Version][npm-img]][npm-url]\n[![Build Status][cli-img]][cli-url]\n[![Support Chat][git-img]][git-url]\n\n[PostCSS Short Border] lets you omit sides within `border-` properties in CSS.\nIt also lets you fully define individual values on the `border` property using\ndividers (`/`).\n\n```pcss\n.example-1 {\n  border-color: blue blue *;\n}\n\n.example-2 {\n  border-width: 1px *;\n}\n\n.example-3 {\n  border: 1px 2px / solid / red orange;\n}\n\n/* becomes */\n\n.example-1 {\n  border-top-color: blue;\n  border-right-color: blue;\n  border-left-color: blue;\n}\n\n.example-2 {\n  border-top-width: 1px;\n  border-bottom-width: 1px;\n}\n\n.example-3 {\n  border-width: 1px 2px;\n  border-style: solid;\n  border-color: red orange;\n}\n```\n\n## Usage\n\nAdd [PostCSS Short Border] to your project:\n\n```bash\nnpm install postcss-short-border --save-dev\n```\n\nUse [PostCSS Short Border] to process your CSS:\n\n```js\nconst postcssShortBorder = require('postcss-short-border');\n\npostcssShortBorder.process(YOUR_CSS /*, processOptions, pluginOptions */);\n```\n\nOr use it as a [PostCSS] plugin:\n\n```js\nconst postcss = require('postcss');\nconst postcssShortBorder = require('postcss-short-border');\n\npostcss([\n  postcssShortBorder(/* pluginOptions */)\n]).process(YOUR_CSS /*, processOptions */);\n```\n\n[PostCSS Short Border] runs in all Node environments, with special instructions for:\n\n| [Node](INSTALL.md#node) | [PostCSS CLI](INSTALL.md#postcss-cli) | [Webpack](INSTALL.md#webpack) | [Create React App](INSTALL.md#create-react-app) | [Gulp](INSTALL.md#gulp) | [Grunt](INSTALL.md#grunt) |\n| --- | --- | --- | --- | --- | --- |\n\n## Options\n\n#### prefix\n\nThe `prefix` option defines a prefix required by properties being transformed.\nWrapping dashes are automatically applied, so that `x` would transform\n`-x-border`.\n\n```js\npostcssShortBorder({ prefix: 'x' });\n```\n\n```pcss\n.example-1 {\n  -x-border-color: blue blue *;\n}\n\n/* becomes */\n\n.example-1 {\n  border-top-color: blue;\n  border-right-color: blue;\n  border-left-color: blue;\n}\n```\n\n#### skip\n\nThe `skip` option defines the skip token used to ignore portions of the\nshorthand.\n\n```js\npostcssShortBorder({ skip: '-' });\n```\n\n```pcss\n.example-1 {\n  border-color: blue blue -;\n}\n\n/* becomes */\n\n.example-1 {\n  border-top-color: blue;\n  border-right-color: blue;\n  border-left-color: blue;\n}\n```\n\n[cli-img]: https://img.shields.io/travis/jonathantneal/postcss-short-border.svg\n[cli-url]: https://travis-ci.org/jonathantneal/postcss-short-border\n[git-img]: https://img.shields.io/badge/support-chat-blue.svg\n[git-url]: https://gitter.im/postcss/postcss\n[npm-img]: https://img.shields.io/npm/v/postcss-short-border.svg\n[npm-url]: https://www.npmjs.com/package/postcss-short-border\n\n[PostCSS]: https://github.com/postcss/postcss\n[PostCSS Short Border]: https://github.com/jonathantneal/postcss-short-border\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcsstools%2Fpostcss-short-border","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcsstools%2Fpostcss-short-border","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcsstools%2Fpostcss-short-border/lists"}