profile
viewpoint
If you are wondering where the data of this site comes from, please visit https://api.github.com/users/FormidableLabs/events. GitMemory does not store any data, but only uses NGINX to cache data for a period of time. The idea behind GitMemory is simply to give users a better reading experience.
Formidable FormidableLabs Seattle, WA https://formidable.com We design and develop web apps, train engineers at startups and Fortune 500 companies, and improve the modern web with open source software.

FormidableLabs/appr 380

Open React Native PR Builds instantly on device

FormidableLabs/builder 308

An npm-based task runner

FormidableLabs/babel-plugin-transform-define 238

Compile time code replacement for babel similar to Webpack's DefinePlugin

FormidableLabs/aws-lambda-serverless-reference 65

A reference application for AWS + serverless framework.

FormidableLabs/biff 28

Flux architecture made easy

FormidableLabs/babel-plugin-module-alias 7

Rewrite/Resolve require/import paths to different values in Babel.

FormidableLabs/aws-serverless-express-edge 6

Run serverless applications on the edge in Amazon CloudFront by leveraging Lambda@Edge.

FormidableLabs/abstract-log 4

A micro logging wrapper for shims, logging frameworks, console logs, etc.

FormidableLabs/babel-plugin-replace-require 4

Replace require output generated from import calls.

startedFormidableLabs/prism-react-renderer

started time in 11 minutes

startedFormidableLabs/spectacle

started time in an hour

startedFormidableLabs/react-live

started time in an hour

startedFormidableLabs/react-game-kit

started time in an hour

startedFormidableLabs/react-native-app-auth

started time in an hour

startedFormidableLabs/react-native-app-auth

started time in an hour

startedFormidableLabs/victory

started time in an hour

startedFormidableLabs/nodejs-dashboard

started time in an hour

startedFormidableLabs/victory

started time in 2 hours

issue openedFormidableLabs/urql

Type error in subscriptionExchange for forwardSubscription

Hello all 👋, <!-- Please describe your bug clearly and concisely. Include a screenshot or a reproduction to illustrate the bug and how to reproduce it. Please also leave a note on what version of urql you're using and include a list of exchanges (if any). -->

urql version & exchanges: 2.0.5 subscriptions-transport-ws : 0.9.19

Steps to reproduce

1.Follow the official example : https://formidable.com/open-source/urql/docs/advanced/subscriptions/#setting-up-subscriptions-transport-ws

  1. Type error on forwardSubscription return type against return subscriptionClient.request(operation); :

<details><summary>Error log</summary>

src/config/urql/index.tsx:96:9 - error TS2322: Type '(operation: SubscriptionOperation) => Observable<ExecutionResult<{ [key: string]: any; }, { [key: string]: any; }>>' is not assignable to type 'SubscriptionForwarder'.
  Call signature return types 'Observable<ExecutionResult<{ [key: string]: any; }, { [key: string]: any; }>>' and 'ObservableLike<ExecutionResult>' are incompatible.
    The types of 'subscribe' are incompatible between these types.
      Type '(observer: Observer<ExecutionResult<{ [key: string]: any; }, { [key: string]: any; }>>) => { unsubscribe: () => void; }' is not assignable to type '(observer: ObserverLike<ExecutionResult>) => { unsubscribe: () => void; }'.
        Types of parameters 'observer' and 'observer' are incompatible.
          Type 'ObserverLike<ExecutionResult>' is not assignable to type 'Observer<ExecutionResult<{ [key: string]: any; }, { [key: string]: any; }>>'.
            Types of property 'next' are incompatible.
              Type '(value: ExecutionResult) => void' is not assignable to type '(value: ExecutionResult<{ [key: string]: any; }, { [key: string]: any; }>) => void'.
                Types of parameters 'value' and 'value' are incompatible.
                  Type 'ExecutionResult<{ [key: string]: any; }, { [key: string]: any; }>' is not assignable to type 'ExecutionResult'.
                    Type 'ExecutionResult<{ [key: string]: any; }, { [key: string]: any; }>' is not assignable to type '{ errors?: (string | Error | Partial<GraphQLError>)[] | undefined; data?: Record<string, any> | null | undefined; extensions?: Record<string, any> | undefined; hasNext?: boolean | undefined; }'.
                      Types of property 'errors' are incompatible.
                        Type 'readonly GraphQLError[] | undefined' is not assignable to type '(string | Error | Partial<GraphQLError>)[] | undefined'.
                          The type 'readonly GraphQLError[]' is 'readonly' and cannot be assigned to the mutable type '(string | Error | Partial<GraphQLError>)[]'.

96         forwardSubscription(operation) {
           ~~~~~~~~~~~~~~~~~~~

  ../../node_modules/urql/node_modules/@urql/core/dist/types/exchanges/subscription.d.ts:22:5
    22     forwardSubscription: SubscriptionForwarder;
           ~~~~~~~~~~~~~~~~~~~
    The expected type comes from property 'forwardSubscription' which is declared here on type 'SubscriptionExchangeOpts'

</details>

Expected behavior

Actual behavior

<!-- Your issue will be addressed much faster if you include a reproduction. Here are some templates to help you create one:

  • client: https://codesandbox.io/s/urql-issue-template-client-iui0o
  • server: https://codesandbox.io/s/urql-issue-template-server-0ufyz -->

created time in 2 hours

startedFormidableLabs/urql

started time in 3 hours

startedFormidableLabs/victory

started time in 3 hours

release FormidableLabs/urql

@urql/storage-rn@0.1.0

released time in 5 hours

created tagFormidableLabs/urql

tag@urql/storage-rn@0.1.0

The highly customizable and versatile GraphQL client with which you add on features like normalized caching as you grow.

created time in 5 hours

push eventFormidableLabs/urql

Kadi Kraman

commit sha 0fe23c53a6c2bc5a4c6c8ea1880f5f7df6065d2f

(graphcache) offline storage for React Native (#1949) * Initial setup for graphcache-rn-async-storage * Add readme docs for @urql/graphcache-rn-async-storage * Add a note on @urql/exchange-graphcache/default-storage to the docs site * Add a changelog and initial release * Make default keys less shouty * Export storage options type * Remove optional chaining * Add arg to catch block (else build fails with TypeError: Cannot read property 'type' of null) * Clean up NetInfo if the exchange is reinitialised * Rename package to @urql/storage-rn * Add tests for read and write metadata * Add tests for write data * Add tests for onOnline * Save data under a single key * Simplify and add tests for readData * Add a clear method to rn storage * Merge data from all days * Move async storage calls inline * Ensure deleted keys are also removed from old cache * Use forEach instead of spread * Simplify assignment logic Co-authored-by: Grant Sander <gksander93@gmail.com>

view details

push time in 5 hours

delete branch FormidableLabs/urql

delete branch : graphcache-rn-async-storage

delete time in 5 hours

PR merged FormidableLabs/urql

(graphcache) offline storage for React Native

Summary

The default storage included in Graphcache isn't compatible with React Native. This adds a React Native-compatible version of the default storage that relies on AsyncStorage for persisting the data, and NetInfo to determine when the app is offline.

Set of changes

  • new package @urql/storage-rn
  • readme instructions
  • note about the RN storage in the docs site
+736 -1

2 comments

10 changed files

kadikraman

pr closed time in 5 hours

PullRequestReviewEvent

startedFormidableLabs/nuka-carousel

started time in 5 hours

startedFormidableLabs/prism-react-renderer

started time in 8 hours

issue closedFormidableLabs/victory

Question - Is it possible to add multiple y-axes on the same side but do not overlap the chart data area?

Bugs and Questions

Checklist

  • [x] This is not a victory-native specific issue. (Issues that only appear in victory-native should be opened here)

  • [x] I have read through the FAQ and Guides before asking a question

  • [x] I am using the latest version of Victory

  • [x] I've searched open issues to make sure I'm not opening a duplicate issue

The Problem

I'm working to build a line chart that supports multiple y axes, I've found the showcase from the documentation of Victory but the y-axis in the middle is overlapping with the chart data.

https://formidable.com/open-source/victory/gallery/multiple-dependent-axes/

Is there a way to style or make it on the leftmost or outside the chart data area like this?

Reproduction

The currently sample from Victory: https://jsfiddle.net/ngmikeng/5m73ktja/

closed time in 10 hours

ngmikeng

issue commentFormidableLabs/victory

Question - Is it possible to add multiple y-axes on the same side but do not overlap the chart data area?

In the fiddle, you will get the desired result if you: change xOffsets = [100, 50, 300]; set padding={100} on VictoryChart

image

You can also adjust padding for individual sides. For example, padding={{left: 100, right: 50, top: 50, bottom: 50 }}. In the padding={100} example, it pads all sides of the chart so it will shrink the whole chart within the container. You may want to pad the left more than the other sides and adjust the offsets accordingly if you want the chart to fill as much of the container as possible.

Thank you a lot for pointing out @tgalfin , The key property here is the padding of the VictoryChart component, now I can have the result as expected. https://jsfiddle.net/ngmikeng/t9sbnye2/

ngmikeng

comment created time in 10 hours

startedFormidableLabs/react-live

started time in 12 hours

startedFormidableLabs/react-native-app-auth

started time in 13 hours

startedFormidableLabs/react-swipeable

started time in 14 hours

startedFormidableLabs/prism-react-renderer

started time in 15 hours

startedFormidableLabs/prism-react-renderer

started time in 15 hours

startedFormidableLabs/nuka-carousel

started time in 15 hours

issue commentFormidableLabs/victory

Question - Is it possible to add multiple y-axes on the same side but do not overlap the chart data area?

In the fiddle, you will get the desired result if you: change xOffsets = [100, 50, 300]; set padding={100} on VictoryChart

image

You can also adjust padding for individual sides. For example, padding={{left: 100, right: 50, top: 50, bottom: 50 }}. In the padding={100} example, it pads all sides of the chart so it will shrink the whole chart within the container. You may want to pad the left more than the other sides and adjust the offsets accordingly if you want the chart to fill as much of the container as possible.

ngmikeng

comment created time in 17 hours