{"id":21883808,"url":"https://github.com/vovanr/react-price","last_synced_at":"2025-04-15T06:28:19.408Z","repository":{"id":57342674,"uuid":"50946794","full_name":"VovanR/react-price","owner":"VovanR","description":"React price component","archived":false,"fork":false,"pushed_at":"2024-04-23T00:12:09.000Z","size":77,"stargazers_count":9,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-04-12T12:08:15.136Z","etag":null,"topics":["react","react-component"],"latest_commit_sha":null,"homepage":"https://vovanr.github.io/react-price","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/VovanR.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2016-02-02T19:41:40.000Z","updated_at":"2020-07-02T08:15:38.000Z","dependencies_parsed_at":"2024-11-28T13:46:47.638Z","dependency_job_id":null,"html_url":"https://github.com/VovanR/react-price","commit_stats":{"total_commits":54,"total_committers":1,"mean_commits":54.0,"dds":0.0,"last_synced_commit":"a13af44b2f19186b444bc5899c01c4de33c90569"},"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VovanR%2Freact-price","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VovanR%2Freact-price/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VovanR%2Freact-price/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/VovanR%2Freact-price/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/VovanR","download_url":"https://codeload.github.com/VovanR/react-price/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249019924,"owners_count":21199452,"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":["react","react-component"],"created_at":"2024-11-28T09:46:56.050Z","updated_at":"2025-04-15T06:28:19.401Z","avatar_url":"https://github.com/VovanR.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# react-price\n\n[![Commitizen friendly][commitizen-image]][commitizen-url]\n[![XO code style][codestyle-image]][codestyle-url]\n\n[![NPM version][npm-image]][npm-url]\n[![Build Status][travis-image]][travis-url]\n[![Dependency Status][depstat-image]][depstat-url]\n[![DevDependency Status][depstat-dev-image]][depstat-dev-url]\n\n\u003e React price component\n\nDemo: [vovanr.github.io/react-price][demo]\n\n![](preview.png)\n\n## Install\n\n```shell\nnpm install --save react-price\n```\n\n## Usage\nSee: [example](example/app.jsx)\n\n```js\nimport Price from 'react-price';\n\nconst price = (\n  \u003cdiv\u003e\n    \u003cdiv\u003e\n      \u003csmall\u003eOld: \u003c/small\u003e\n      \u003cPrice cost={100} currency=\"$\" type=\"old\"/\u003e\n    \u003c/div\u003e\n    \u003cdiv\u003e\n      \u003csmall\u003eNew: \u003c/small\u003e\n      \u003cPrice cost={91.55} currency=\"€\"/\u003e\n    \u003c/div\u003e\n    \u003cdiv\u003e\n      \u003csmall\u003eSale: \u003c/small\u003e\n      \u003cPrice cost=\"7 793\" currency=\"₽\"/\u003e\n    \u003c/div\u003e\n  \u003c/div\u003e\n);\n\nReactDOM.render(price, document.getElementById('app'));\n```\n\n## Api\n\n```js\nPrice.propTypes = {\n  cost: PropTypes.any,\n  className: PropTypes.string,\n  currency: PropTypes.any,\n  currencyFirst: PropTypes.bool,\n  prefix: PropTypes.any,\n  postfix: PropTypes.any,\n  type: PropTypes.oneOf([\n    'def',\n    'old'\n  ]),\n};\nPrice.defaultProps = {\n  cost: null,\n  className: '',\n  currency: null,\n  currencyFirst: false,\n  prefix: null,\n  postfix: null,\n  type: 'def'\n};\n```\n\n## License\nMIT © [Vladimir Rodkin](https://github.com/VovanR)\n\n[demo]: https://vovanr.github.io/react-price\n\n[commitizen-url]: https://commitizen.github.io/cz-cli/\n[commitizen-image]: https://img.shields.io/badge/commitizen-friendly-brightgreen.svg?style=flat-square\n\n[codestyle-url]: https://github.com/xojs/xo\n[codestyle-image]: https://img.shields.io/badge/code_style-XO-5ed9c7.svg?style=flat-square\n\n[npm-url]: https://npmjs.org/package/react-price\n[npm-image]: https://img.shields.io/npm/v/react-price.svg?style=flat-square\n\n[travis-url]: https://travis-ci.org/VovanR/react-price\n[travis-image]: https://img.shields.io/travis/VovanR/react-price.svg?style=flat-square\n\n[depstat-url]: https://david-dm.org/VovanR/react-price\n[depstat-image]: https://david-dm.org/VovanR/react-price.svg?style=flat-square\n\n[depstat-dev-url]: https://david-dm.org/VovanR/react-price\n[depstat-dev-image]: https://david-dm.org/VovanR/react-price/dev-status.svg?style=flat-square\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvovanr%2Freact-price","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvovanr%2Freact-price","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvovanr%2Freact-price/lists"}