Skip to content
This repository was archived by the owner on Feb 7, 2019. It is now read-only.
This repository was archived by the owner on Feb 7, 2019. It is now read-only.

Ditch Shadow DOM and HTML Imports in the name of compat? #268

@potch

Description

@potch

One of the big problems with Brick in its current form is that its use of Shadow DOM and HTML Imports polyfills severely limits the environments in which Brick will work correctly. The polyfills are slow, incomplete, and break CSP. I know a large amount of effort was spent moving to use the polyfills, but I'm asking for a re-evaluation. My proposal is to double down on Custom Elements, but back away from other WC specs until they are in deployment:

  • Change individual components to use only Custom Elements
  • Use specific CSS classes to namespace styles in an extendable/overwritable way that is unlikely to conflict with other classes on the page.
  • Use browserify to perform build on individual components as well as a bundle. browserify knows how to inline styles or markup needed for a component, and lets us use 'require'-style imports for better code structure.

Thoughts? /cc @mozbrick/owners

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions