Code Monkey home page Code Monkey logo

patternlab-php's Introduction

About Pattern Lab

The PHP version of Pattern Lab is, at its core, a static site generator. It combines platform-agnostic assets, like the Mustache-based patterns and the JavaScript-based viewer, with a PHP-based "builder" that transforms and dynamically builds the Pattern Lab site. By making it a static site generator, Pattern Lab strongly separates patterns, data, and presentation from build logic.

Demo

You can play with a demo of the front-end of Pattern Lab at demo.patternlab.io.

Getting Started

Working with Patterns

Patterns are the core element of Pattern Lab. Understanding how they work is the key to getting the most out of the system. Patterns use Mustache so please read Mustache's docs as well.

Creating & Working With Dynamic Data for a Pattern

The PHP version of Pattern Lab utilizes Mustache as the template language for patterns. In addition to allowing for the inclusion of one pattern within another it also gives pattern developers the ability to include variables. This means that attributes like image sources can be centralized in one file for easy modification across one or more patterns. The PHP version of Pattern Lab uses a JSON file, source/_data/data.json, to centralize many of these attributes.

Using Pattern Lab's Advanced Features

By default, the Pattern Lab assets can be manually generated and the Pattern Lab site manually refreshed but who wants to waste time doing that? Here are some ways that Pattern Lab can make your development workflow a little smoother:


Translations of this document


Sobre Pattern Lab

A versão de PHP Pattern Lab é , em sua essência, um gerador de site estático . Ele combina ativos independentes de plataforma , como os [ Mustache] ( http://mustache.github.io/ ) baseados em padrões e o visualizador baseado em JavaScript , com um " construtor " baseado em PHP que transforma e constroi dinamicamente o Pattern Lab Base. Ao torná-lo um gerador de site estático , Pattern Lab separa fortemente padrões , dados e apresentação da lógica de construção.

Demonstração

Você pode ver a demonstração em demo.patternlab.io.

VAMOS COMEÇAR

Trabalhando com Padrões

Os padrões são o elemento central do Pattern Lab. Entender como elas funcionam é a chave para obter o máximo proveito do sistema. padrões de usarMustache apenas leia por favor Mustache's docs também.

Criando e Trabalhando com dados dinâmicos para um Padrão

A versão de PHP Pattern Lab utiliza Mustache como o modelo de linguagem de padrões . Além de permitir que para aiinclusão de um padrão dentro de outro ele também dá aos desenvolvedores a capacidade padrão para incluir variáveis. Isto significa que atributos como fontes de imagem pode ser centralizado em um único arquivo para facilitar a modificação em uma ou mais padrões. A versão de PHP Pattern Lab utiliza arquivos JSON ', source/_data/data.json, para centralizar muitos desses atributos.

##Usando Padrão de Laboratório Recursos Avançados

Por padrão , os ativos Padrão Lab podem ser gerados manualmente eo site Lab Padrão atualizado manualmente mas quem quer perder tempo fazendo isso? Aqui estão algumas maneiras que Pattern Lab pode fazer o seu fluxo de trabalho de desenvolvimento um pouco mais suave :

patternlab-php's People

Contributors

dmolsen avatar bradfrost avatar alienlebarge avatar faustgertz avatar lemacedo avatar griffinartworks avatar ageibert avatar illepic avatar coryrylan avatar jamiemagique avatar jasonlcrane avatar kevin-heil avatar levito avatar kamilwaheed avatar patternlab avatar

Watchers

Tobias Davis avatar James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.