Learn about our RFC process, Open RFC meetings & more.Join in the discussion! »

svelte-grid-responsive

0.3.0 • Public • Published

Svelte Grid Responsive

npm versionLicense: MITBuild StatusNetlify Status

Responsive grid system based on Bootstrap for Svelte.

Installation

npm i svelte-grid-responsive
// OR
yarn add svelte-grid-responsive

Note: to use this library in sapper, install as devDependency. See the link.

Demo Link

Local demo:

git clone https://github.com/andrelmlins/svelte-grid-responsive.git
cd svelte-grid-responsive
yarn && yarn start

Examples

An example of how to use the library:

<script>
  import Grid from "svelte-grid-responsive";
</script>
 
<Grid container gutter={12}>
  <Grid xs={12} md={4} lg={3}>
    xs=12 md=4 lg=3
  </Grid>
  <Grid xs={12} md={4} lg={3}>
    xs=12 md=4 lg=3
  </Grid>
  <Grid xs={12} md={4} lg={3}>
    xs=12 md=4 lg=3
  </Grid>
  <Grid xs={12} md={4} lg={3}>
    xs=12 md=4 lg=3
  </Grid>
</Grid>

Properties

Component props:

Prop Default Type Description
container false bool Defines whether the grid is a container
gutter false number Grid spacing in the container
columns 12 number Setting columns count in the container
xs false number Size in extra small screen
sm false number Size in small screen
md false number Size in medium screen
lg false number Size in large screen
xl false number Size in extra large screen

NPM Statistics

Download stats for this NPM package

NPM

License

Svelte Grid Responsive is open source software licensed as MIT.

Install

npm i svelte-grid-responsive

DownloadsWeekly Downloads

15

Version

0.3.0

License

MIT

Unpacked Size

32.2 kB

Total Files

7

Last publish

Collaborators

  • avatar