sharingbuttons.io

Quickly generate social sharing buttons with a tiny performance footprint

  • 所有者: mxstbr/sharingbuttons.io
  • 平台:
  • 许可证: MIT License
  • 分类:
  • 主题:
  • 喜欢:
    0
      比较:

Github星跟踪图

sharingbuttons.io

A web app to quickly generate social sharing buttons that do not track the user.

Screenshot of sharingbuttons.io

Built using React.js and utilising the Flux application architecture.

Getting up and running

After cloning this repository, run npm install in the root directory to install the dependencies. As soon as all of them are installed, you can npm start in the root directory and open 0.0.0.0:3000 in your browser to see your local copy of the app.

Structure

The main part of the application is rendered in the App component found at js/components/App.react.js. All of the components can dispatch actions to change things.

Actions

The following actions are available:

  • AppActions.toggleNetwork(network) - Toggles a social network on/off

  • AppActions.setURL(url) - Sets the shared URL

  • AppActions.setText(text) - Sets the shared text

  • AppActions.changeSize(size) - Changes the size of the buttons

  • AppActions.changeIcon(type) - Changes the icon type

For a more in-depth documentation of the available actions, have a look at the AppActions found at js/actions/AppActions.js. All of these actions get picked up by the AppStore, found at js/stores/AppStore.js. The AppStore then changes the data and emits that it changed, which prompts the app to rerender with the new data.

To define a new action, first add the action type to the AppConstants (js/constants/AppConstants.js), then pick up the dispatched action in the AppStore.AppDispatcher.register() function and change something according to the action.

Components

The app is split up across 6 components, all found in js/components. The following components are rendered:

  • App.react.js - The root component that renders the rest of the application. Contains most of the static text found on the page.

  • Generator.react.js - Renders the Generator.

  • SelectionButton.react.js - Renders the options of the Generator.

  • GeneratorCode.react.js - Renders the code to be copied.

  • GeneratorPreview.react.js - Renders the preview page.

  • Header.react.js - Renders the header.

  • PreviewButton.react.js - Renders a preview button.

  • Footer.react.js - Renders the footer.

Contributing

sharingbuttons.io loves community involvement! Take a look at the unassigned open issues, especially the unassigned open requests for help, or open a new issue/make a PR!

Help

If you need help with anything regarding this app, contact me on twitter and I will try to help you as quickly as possible.

License

This project is licensed under the MIT license:

The MIT License (MIT)

Copyright (c) 2015 Maximilian Stoiber

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

主要指标

概览
名称与所有者mxstbr/sharingbuttons.io
主编程语言JavaScript
编程语言CSS (语言数: 3)
平台
许可证MIT License
所有者活动
创建于2015-05-24 09:07:46
推送于2022-06-23 08:32:38
最后一次提交2020-04-08 17:06:28
发布数0
用户参与
星数2.5k
关注者数37
派生数105
提交数174
已启用问题?
问题数76
打开的问题数28
拉请求数22
打开的拉请求数8
关闭的拉请求数6
项目设置
已启用Wiki?
已存档?
是复刻?
已锁定?
是镜像?
是私有?