booleanhunter / ReactJS-AdminLTE

ReactJS version of the original AdminLTE dashboard (EXPERIMENTAL)- https://github.com/almasaeed2010/AdminLTE
Other
2.35k stars 800 forks source link

How to use with Meteor JS? #8

Open thearabbit opened 8 years ago

thearabbit commented 8 years ago

I would like to use this with Meteor JS. But I don't understand to install, config and more... Please help me.

booleanhunter commented 8 years ago

I haven't used MeteorJS before, but using this template along with it should be fairly straighforward. I came across this tutorial, which could help you understand how to use React components with Meteor - http://react-in-meteor.readthedocs.org/en/latest/

Do try it out and let me know if this helps.

bmanturner commented 8 years ago

You'll need to do some manual work to make them readily usable. Example:

import React from 'react';

const InfoTile = ({ children, theme, icon, title, stats, content }) => (
  <div className={`info-box ${theme}`}>
    <span className="info-box-icon">
      <i className={`fa ${icon}`}></i>
    </span>

    <div className="info-box-content">
      <span className="info-box-text">{title}</span>
      <span className="info-box-number">{stats}</span>
      {children}
    </div>

    {content}
  </div>
);

InfoTile.propTypes = {
  content: React.PropTypes.node,
  icon: React.PropTypes.string,
  stats: React.PropTypes.string,
  title: React.PropTypes.string,
  theme: React.PropTypes.string,
  children: React.PropTypes.node
};

InfoTile.defaultProps = {
  content: '',
  icon: 'fa-star-o',
  stats: '0',
  title: 'Default',
  theme: 'bg-aqua'
};

export default InfoTile;
jetdario commented 7 years ago

@thearabbit : how's your installation of this template in MeteorJS? I was planning to do the same.