GithubHelp home page GithubHelp logo

atlassian-archive / brisk-docs Goto Github PK

View Code? Open in Web Editor NEW
16.0 16.0 6.0 8.94 MB

Home for brisk-docs packages - developed by Atlassian

Home Page: https://brisk-docs.netlify.com/

License: MIT License

JavaScript 27.04% Shell 0.37% TypeScript 72.60%

brisk-docs's People

Contributors

ajaymathur avatar blasz avatar dependabot[bot] avatar dpisani-atl avatar github-actions[bot] avatar highvoltag3 avatar jackbrown avatar noviny avatar pyupew avatar qburst-aparna avatar ryanbraganza avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

brisk-docs's Issues

Add package for file view and example

I'm thinking about adding an example renderer package that looks something like this:

import File from '@brisk-docs/file-viewer'

NB: Within brisk itself, this would be available as <File /> component in all mdx - meaning you don't need to import it.

type Props = {
    runnable: false | 'react' | 'node'
    sandbox: boolean
    sandboxConfig: {} // pass this down to codesandboxer
    lines: [number, number] || Array<[number, number]> // The lines in the file to show
}

Requires a babel loader under the hood

const a = () => (
    <File path="./something/Component.js" runnable="react" />
)

I'm curious if we want to include children like docz does - I'm a fan of
having actual files, because it makes the components multi-purpose,
and means for things like codesandboxer you can't hide imports/required files
This makes certain kinds of simple example very easy to compose though.

const a = () => (
    <File runnable="react">
        <Button onClick={() => console.log('clicked the button')}>
            Some Text
        </Button>
    </File>
)

use file extension to add ONLY the appropriate code highlighting syntax from whatever syntax highlighting.

styled components version conflicts with other styled components

Currently Brisk pulls its own styled-components library, which conflicts with the version we have installed already. Because of that Brisk just doesn't work when you're trying to use local packages.

If I install manually a version of styled-components that we use, it almost works, but it stops on SSR and never goes to the client. Console errors are complaining about drag&drop in navigation

How do I sort items on the main page?

Currently there is no way to sort all the items on the main page: some of them, that are coming from the docs array, can be sorted relative to each other. But I can not move "packages" or "getting started" page into a different location.

Low priority: Getting error when tried to create docs for other mono-repo

Hey, I tried running brisk to create docs website for extract-react-types but I got the following error:

ModuleBuildError: Module build failed (from /Users/amathur/workspace/extract-react-types/node_modules/next/dist/build/webpack/loaders/next-babel-loader.js):
TypeError: Property expression of JSXExpressionContainer expected node to be of a type ["Expression","JSXEmptyExpression"] but instead got null
    at Object.validate (/Users/amathur/workspace/extract-react-types/node_modules/next/node_modules/@babel/types/lib/definitions/utils.js:131:13)
    at validateField (/Users/amathur/workspace/extract-react-types/node_modules/next/node_modules/@babel/types/lib/validators/validate.js:22:9)
    at validate (/Users/amathur/workspace/extract-react-types/node_modules/next/node_modules/@babel/types/lib/validators/validate.js:16:3)
    at builder (/Users/amathur/workspace/extract-react-types/node_modules/next/node_modules/@babel/types/lib/builders/builder.js:46:27)
    at Object.JSXExpressionContainer (/Users/amathur/workspace/extract-react-types/node_modules/next/node_modules/@babel/types/lib/builders/generated/index.js:767:31)
    at propertiesReducer (/Users/amathur/workspace/extract-react-types/node_modules/babel-plugin-styled-components/lib/visitors/transpileCssProp.js:124:83)
    at Array.reduce (<anonymous>)
    at /Users/amathur/workspace/extract-react-types/node_modules/babel-plugin-styled-components/lib/visitors/transpileCssProp.js:110:39
    at PluginPass.JSXAttribute (/Users/amathur/workspace/extract-react-types/node_modules/babel-plugin-styled-components/lib/index.js:32:46)
    at NodePath._call (/Users/amathur/workspace/extract-react-types/node_modules/@babel/traverse/lib/path/context.js:53:20)
    at NodePath.call (/Users/amathur/workspace/extract-react-types/node_modules/@babel/traverse/lib/path/context.js:40:17)
    at NodePath.visit (/Users/amathur/workspace/extract-react-types/node_modules/@babel/traverse/lib/path/context.js:88:12)
    at TraversalContext.visitQueue (/Users/amathur/workspace/extract-react-types/node_modules/@babel/traverse/lib/context.js:118:16)
    at TraversalContext.visitMultiple (/Users/amathur/workspace/extract-react-types/node_modules/@babel/traverse/lib/context.js:85:17)
    at TraversalContext.visit (/Users/amathur/workspace/extract-react-types/node_modules/@babel/traverse/lib/context.js:144:19)
    at Function.traverse.node (/Users/amathur/workspace/extract-react-types/node_modules/@babel/traverse/lib/index.js:94:17)
    at runLoaders (/Users/amathur/workspace/extract-react-types/node_modules/next/node_modules/webpack/lib/NormalModule.js:301:20)
    at /Users/amathur/workspace/extract-react-types/node_modules/loader-runner/lib/LoaderRunner.js:367:11
    at /Users/amathur/workspace/extract-react-types/node_modules/loader-runner/lib/LoaderRunner.js:233:18
    at context.callback (/Users/amathur/workspace/extract-react-types/node_modules/loader-runner/lib/LoaderRunner.js:111:13)
    at loader.call.then.err (/Users/amathur/workspace/extract-react-types/node_modules/next/node_modules/babel-loader/lib/index.js:45:103)
    at process._tickCallback (internal/process/next_tick.js:68:7)

Please treat this issue as low priority. I just wanted to surface this. Thanks.

How do I change an image on the main page?

Pictures on the main pages resolved via paths relative to the build folder from those images that already exist somewhere on the website. Currently, I can not specify an independent link to an image, only via weird workarounds like manually copy-pasting images to the build folder.

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.