Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gatsby-link: add withPrefix to index.d.ts #2887

Closed
codekiln opened this issue Nov 11, 2017 · 0 comments · Fixed by #2888
Closed

gatsby-link: add withPrefix to index.d.ts #2887

codekiln opened this issue Nov 11, 2017 · 0 comments · Fixed by #2888

Comments

@codekiln
Copy link
Contributor

codekiln commented Nov 11, 2017

Recently the gatsby-link withPrefix helper was added. It would be helpful to have this also added to gatsby-link's index.d.ts, so this function could be used in typescript.

-------------- contributing side note --------------

In following the contributing guidelines, I downloaded a latest forked Gatsby source, ran yarn run bootstrap, and then ran tests locally before making modifications, which turned up eight tests failures out of the box. I see that some recent PR test run jobs #4773.1 and #4773.2 have also exhibited the same failures on Travis. Are these test failures common? If so, what is the associated issue and the recommended procedure for resolving them?

Summary of all failing tests
 FAIL  packages/gatsby/cache-dir/__tests__/loader.js
  ● Loader › You can enqueue paths

    TypeError: loader.empty is not a function
      
      at Object.beforeEach (packages/gatsby/cache-dir/__tests__/loader.js:5:12)
          at Promise (<anonymous>)
      at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)
          at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

  ● Loader › You can enqueue paths

    TypeError: loader.enqueue is not a function
      
      at Object.test (packages/gatsby/cache-dir/__tests__/loader.js:21:12)
          at Promise (<anonymous>)
      at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)
          at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

  ● Loader › FIFO by default

    TypeError: loader.empty is not a function
      
      at Object.beforeEach (packages/gatsby/cache-dir/__tests__/loader.js:5:12)
          at Promise (<anonymous>)
      at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)
          at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

  ● Loader › FIFO by default

    TypeError: loader.enqueue is not a function
      
      at Object.test (packages/gatsby/cache-dir/__tests__/loader.js:27:12)
          at Promise (<anonymous>)
      at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)
          at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

  ● Loader › Paths enqueued more times are prioritized

    TypeError: loader.empty is not a function
      
      at Object.beforeEach (packages/gatsby/cache-dir/__tests__/loader.js:5:12)
          at Promise (<anonymous>)
      at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)
          at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

  ● Loader › Paths enqueued more times are prioritized

    TypeError: loader.enqueue is not a function
      
      at Object.test (packages/gatsby/cache-dir/__tests__/loader.js:33:12)
          at Promise (<anonymous>)
      at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)
          at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

  ● Loader › Paths are only added once to the queue

    TypeError: loader.empty is not a function
      
      at Object.beforeEach (packages/gatsby/cache-dir/__tests__/loader.js:5:12)
          at Promise (<anonymous>)
      at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)
          at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

  ● Loader › Paths are only added once to the queue

    TypeError: loader.enqueue is not a function
      
      at Object.test (packages/gatsby/cache-dir/__tests__/loader.js:40:12)
          at Promise (<anonymous>)
      at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)
          at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

  ● Loader › You can't enqueue paths that don't exist

    TypeError: loader.empty is not a function
      
      at Object.beforeEach (packages/gatsby/cache-dir/__tests__/loader.js:5:12)
          at Promise (<anonymous>)
      at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)
          at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

  ● Loader › You can't enqueue paths that don't exist

    TypeError: loader.enqueue is not a function
      
      at Object.test (packages/gatsby/cache-dir/__tests__/loader.js:50:19)
          at Promise (<anonymous>)
      at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)
          at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

  ● Loader › You can dequeue a path

    TypeError: loader.empty is not a function
      
      at Object.beforeEach (packages/gatsby/cache-dir/__tests__/loader.js:5:12)
          at Promise (<anonymous>)
      at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)
          at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

  ● Loader › You can dequeue a path

    TypeError: loader.enqueue is not a function
      
      at Object.test (packages/gatsby/cache-dir/__tests__/loader.js:54:12)
          at Promise (<anonymous>)
      at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)
          at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

  ● Loader › You can get the order of a path

    TypeError: loader.empty is not a function
      
      at Object.beforeEach (packages/gatsby/cache-dir/__tests__/loader.js:5:12)
          at Promise (<anonymous>)
      at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)
          at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

  ● Loader › You can get the order of a path

    TypeError: loader.enqueue is not a function
      
      at Object.test (packages/gatsby/cache-dir/__tests__/loader.js:59:12)
          at Promise (<anonymous>)
      at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)
          at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

  ● Loader › Resources are ordered correctly by count

    TypeError: loader.empty is not a function
      
      at Object.beforeEach (packages/gatsby/cache-dir/__tests__/loader.js:5:12)
          at Promise (<anonymous>)
      at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)
          at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

  ● Loader › Resources are ordered correctly by count

    TypeError: loader.enqueue is not a function
      
      at Object.test (packages/gatsby/cache-dir/__tests__/loader.js:65:12)
          at Promise (<anonymous>)
      at Promise.resolve.then.el (node_modules/p-map/index.js:46:16)
          at <anonymous>
      at process._tickCallback (internal/process/next_tick.js:188:7)

This was referenced Jan 12, 2022
This was referenced Feb 9, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
1 participant