LuccaSA / lucca-front

documentation
https://prisme.lucca.io
MIT License
40 stars 4 forks source link

ng-material VS ng-bootstrap #19

Closed lucienbertin closed 7 years ago

lucienbertin commented 7 years ago

ng-material - ng-bootstrap

the idea is that we're gonna need modals, popovers, tooltips, selects and other usefull components and in the first version we're just gonna let a third party lib do it for us

points to check

Riron commented 7 years ago

there's no popover like component in material, check ux guidelines, that might explain why

lucienbertin commented 7 years ago

i did a rapid PoC of using both at the same time, its definitely possible but the vendor.js takes a hit

import { NgbRootModule } from '@ng-bootstrap/ng-bootstrap'

laods the full ng-bootstrap library -> vendor + 0.21MB

import { NgbTooltipModule, NgbTooltipConfig } from '@ng-bootstrap/ng-bootstrap'

only import the tooltip -> vendor + 0.21MB, same as importing the whole module

import { NgbTooltipModule } from '@ng-bootstrap/ng-bootstrap/tooltip/tooltip.module'
import {NgbTooltipConfig} from '@ng-bootstrap/ng-bootstrap/tooltip/tooltip-config';

deep import of the tooltip -> vendor + 0.02MB, vendor doesnt contains the whole ng-bootstrap code but deep import are not officially supported and are considered antipatterns

So there is nothing preventing lucca-front to provide css styling for both ng-material and ng-bootstrap

lucienbertin commented 7 years ago

as there is no problem in having both libs, css stylin for both will be produced on a component by component basis