apollo-elements/apollo-elements

View on GitHub

Showing 6 of 52 total issues

Function eleventy has 87 lines of code (exceeds 25 allowed). Consider refactoring.
Open

  eleventy(eleventyConfig) {
    // eleventyConfig.addPlugin(inclusiveLangPlugin);
    eleventyConfig.addPlugin(helmet);
    eleventyConfig.addPlugin(footnotes);

Severity: Major
Found in rocket.config.js - About 3 hrs to fix

    Function githubTag has 41 lines of code (exceeds 25 allowed). Consider refactoring.
    Open

    export function githubTag(engine) {
      return {
        parse(tagToken) {
          this.repo = tagToken.args;
        },
    Severity: Minor
    Found in packages/docs/rocket-plugins/liquid/github.js - About 1 hr to fix

      Function setupWrap has 41 lines of code (exceeds 25 allowed). Consider refactoring.
      Open

      export function setupWrap(config) {
        return function(plugins) {
          if (!plugins.find(isPlugin(name))) {
            const plugin = function wrapCopy({ page }) {
              return function transformer(tree, file, next) {
      Severity: Minor
      Found in packages/docs/rocket-plugins/wrap.js - About 1 hr to fix

        Function render has 34 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

            async render(scope, hash) {
              const url = new URL(`/repos/${this.repo}`, 'https://api.github.com/');
              const headers = { 'Accept': 'application/vnd.github.v3+json' };
              const repo = await fetch(url.toString(), { headers }).then(x => x.json());
              return `
        Severity: Minor
        Found in packages/docs/rocket-plugins/liquid/github.js - About 1 hr to fix

          Function transformer has 31 lines of code (exceeds 25 allowed). Consider refactoring.
          Open

                  return function transformer(tree, file, next) {
                    visit(tree, 'code', function copyWrapper(node, index, parent) {
                      for (const [command, fn] of Object.entries(config)) {
                        if (!node.meta) return node;
                        const [directive, ...args] = node.meta
          Severity: Minor
          Found in packages/docs/rocket-plugins/wrap.js - About 1 hr to fix

            Function copyWrapper has 26 lines of code (exceeds 25 allowed). Consider refactoring.
            Open

                      visit(tree, 'code', function copyWrapper(node, index, parent) {
                        for (const [command, fn] of Object.entries(config)) {
                          if (!node.meta) return node;
                          const [directive, ...args] = node.meta
                            .split(' ')
            Severity: Minor
            Found in packages/docs/rocket-plugins/wrap.js - About 1 hr to fix
              Severity
              Category
              Status
              Source
              Language