Skip to content

Optionally vendor third-party dependencies #190

Description

@cardi

I'd like to deploy fluffy as a self-contained app, which would require vendoring some of the external third-party dependencies.

From a cursory search, it looks like the only dependencies are Google Fonts and jQuery.

I'm happy to work on an implementation, if you had any preferences or thoughts on how you'd prefer to go about it.

Google Fonts

This could be a flag in settings.py that would use default system fonts rather than a custom font. (Though I haven't looked at the {S,}CSS files to see how the fonts are specified.)

Maybe an easier solution would be to have a toggle for Google Fonts, and then guarding the stylesheet behind a conditional:

<title>{{branding}}</title>
<link rel="stylesheet" href="https://fonts.googleapis.com/css?family=Josefin+Slab:700|Open+Sans:wght@400;700" />
<link rel="stylesheet" href="{{asset_url('app.css')}}" />
<link rel="icon" href="{{asset_url('img/favicon.ico')}}" />

Then the browser would fall back to the default fonts:

body {
background-color: #005178;
font-family: "Open Sans", Helvetica, Arial, sans-serif;
}

jQuery

For jQuery, a copy would be saved somewhere in fluffy/static/ (maybe fluffy/static/vendor/js?). jQuery is licensed MIT, which probably makes it compatible with including it in the repo.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions