Skip to content

Code Viewer Component #13

@LamboCreeper

Description

@LamboCreeper

Description

Create a new component which renders a codebox with syntax highlighting with a files content. The component should accept the following parameters:

  • path: string (the file path)
  • commit: string (the commit hash)
  • repository: string (the repository name)
  • user: string (the repository owner's name)
  1. Get the file's content from the GitHub API
  2. Decode the base64 within the content property returned
  3. Render the syntax highlighted content.

Each line of the codeblock should be clickable. For the time being it can just open a browser alert with the line number.

User Story

As a user
I want to be able to view code
So that I will can review it

Notes

Metadata

Metadata

Assignees

No one assigned

    Labels

    acceptedThe issue is accepted and PRs are welcomeenhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions