70 Matching Annotations
  1. Sep 2022
    1. multi-tenant data in Amazon S3 requires you to think about how tenant data will be distributed across buckets and keys without undermining the security, manageability, and performance of your SaaS solution.

      Landing without undermining security, manageability, and performance

  2. Jun 2022
    1. If your application runs on-premises, or on another cloud provider, you can use workload identity federation to grant access to external identities without using a service account key. Some client libraries can use Application Default Credentials (ADC) to automatically generate credentials for external identities. To learn more, see Configuring workload identity federation.

      Workload identity federation can be used for authentication on premise applications

  3. Nov 2021
    1. Since it can only load and store numbers, it needs to call out to JavaScript code to do anything interesting (create DOM nodes, make network connections, etc.). WebAssembly code is still inside the browser sandbox and can only use the browser APIs that JavaScript has access to.

      WASM needs to call out to JavaScript code to do anything interesting (create DOM nodes, make network connections, etc.). WebAssembly code is still inside the browser sandbox and can only use the browser APIs that JavaScript has access to.

    2. asm.js subset is basically JavaScript where you can only use numbers (no strings, objects, etc.). This is all you need to run C++ code since everything in C++ is either a number or a pointer to a number, and pointers are also numbers. The C++ address space is just a giant JavaScript array of numbers and pointers are just indices into that array.

      everything in C++ is either a number or a pointer to a number, and pointers are also numbers.

    3. Because our product is written in C++, which can easily be compiled into WebAssembly, Figma is a perfect demonstration of this new format’s power.

      Figma is written in C++, which can easily be compiled into WebAssembly

    4. WebAssembly allows developers to create desktop-quality experiences on the web without compromising on performance.

    1. Ergonomics experts recommend good lighting to reduce eye strain and avoid craning your neck at an unnatural angle. An abundance of natural lighting in your workspace is ideal because it can boost your sense of well-being and energy while reducing eye strain—daylight and access to outdoor views give your eyes opportunities to relax and recover from the strain of staring at a monitor all day.

      Good lighting reduces eye strain. Abundance of natural lighting in your workspace is ideal because it can boost your sense of well-being and energy while reducing eye strain—daylight and access to outdoor views give your eyes opportunities to relax and recover from the strain of staring at a monitor all day.

  4. May 2021
    1. describe a WebSocket in the same way that a regular HTTP endpoint is described, with a request/response message schema, but unlike a regular HTTP endpoint, on a WebSocket there will be zero to many instances of the request/response messages sent in each direction. From a spec perspective, this could be indicated by simply adding a flag to say that the request and/or response messages are streamed. Further information could be added to indicate what streaming protocol should be used (websockets, SSE, newline separated JSON ala Twitter streaming endpoint style).

      Websocket description

  5. Feb 2021
    1. any data that was loaded from another origin without CORS approval, the canvas becomes tainted. A tainted canvas is one which is no longer considered secure, and any attempts to retrieve image data back from the canvas will cause an exception to be thrown.

      Security and tainted canvases

  6. Nov 2020
    1. text resize to fit its parent container, but it's been largely limited to adjusting the font size. The problem with this approach is that making the font smaller is not always the best option for our designs.With variable fonts that contain a width axis, we can adjust the font-stretch property with CSS to condense the font. When we combine this with font-size as well we can create more flexible response text on the web.

      resizing text to fit its parent container

  7. Oct 2020
    1. In all cases, the technique is appropriate for structures with high degree (large fanout). For low-degree structures, outline editors or graph viewers are more effective.

      Use cases for Miller columns: high degree vs low degree structures.

  8. Aug 2020
  9. Jul 2020
    1. "Lifting State Up" is legitimately the answer to the state management problem in React and it's a rock solid one.

      lifting state up

    2. state more logically separated and located in the react tree closer to where it matters.

      State located closer to where it matters

    3. Sure you can hook up different reducers to manage different parts of your application, but the indirection of going through all these action creators and reducers is not optimal.

      On indirection through multiple action creators and reducers for managing different parts of an application

    4. consistently see developers putting all of their state into redux. Not just global application state, but local state as well. This leads to a lot of problems

      global vs local state management. Solutions are not one size fits all.

    5. One of the reasons redux was so successful was the fact that react-redux solved the prop drilling problem. The fact that you could share data across different parts of your tree by simply passing your component into some magical connect function was wonderful.

      Reasons why redux was so successful

  10. May 2020
    1. CreatePagesArgs

      gatsby's createPages extension point allows you to access graphql via CreatePagesArgs

    1. When you’re writing tests for a very specific feature, you should use your UI to test it. But when you’re testing another area of the system that relies on a state from a previous feature: do not use your UI to set up this state.

      Login flow testing in Cypress

    1. If your company does offer you more equity, make sure you ask whether the 409A (or fair market value) of the company is being updated. With revised forecasts given the COVID-19 situation, it may be possible for your company to issue your stock at a lower strike price if the company revalues its 409A.

      Fair market value aka 409A

    1. inline editable UI involve showing errors. You should account for this when thinking about UX. You may also have difficulty achieving the level of accessibility necessary to support mouse events. Touch events will likely also be an issue. Finally, supporting mobile devices can be hard when you have form elements hidden. This will be especially tricky if the UI has to support a mobile layout, because there is no hover to show users whether the field is editable inline on touch screens.

      challenges when using inline editable UI

    1. eventual consistency, SWR will automatically revalidate the data from the origin as soon as data is rendered from the cache.

      eventual consistency when navigation through an app

    1. code exchange with Auth0 and retrieve the user's id_token and access_token which will be stored in memory.

      Auth without backend

    1. Apollo client, help with handling errors, but not as easily as in a REST API

      Error handling conventions

    2. not recommended because it adds more complexity because of things such as: Types Queries Mutators Resolvers High-order components

      Using GraphQL in a simple application (for example, one that uses a few fields in the same way, every time)

  11. redux.js.org redux.js.org
    1. functional programming utility, and is included in Redux as a convenience. You might want to use it to apply several store enhancers in a row.

      store enhancers for redux; All compose does is let you write deeply nested function transformations without the rightward drift of the code. Don't give it too much credit!

    1. speeds up the loading of your application and reduces the payload size of your application.

      Code Splitting is an efficient way to reduce your bundle size

    1. privacy and preventing governments from using the system to compile data on citizens was a primary goal

      The bluetooth system does not use GPS data

    1. The shortcut to run the last plugin in Figma is ⌥ ⌘ + P. Alternatively you can use ⌘+/to bring up the global command menu and type the name of the plugin.

      Figma Plugin shortcuts

    1. less easy when you switch from JavaScript to TypeScript. Running TypeScript on Cloud Functions requires a compilation phase to convert the TypeScript into JavaScript so that it can be executed by the emulator. It adds a bit of a hassle

      a bit of a hassle to compile code that can be executed by the emulator

  12. Apr 2020
    1. Promises and useEffect(async () => ...) are not supported, but you can call an async function inside an effect.. That's why using async directly in the useEffect function isn't allowed.

      async and useEffect

    1. browser behavior of automatically attaching any cookies bounded to https://examplebank.com for any HTTP calls to that domain, including AJAX calls from https://evilunicorns.com to https://examplebank.com

      cookies are attached to HTTP calls

    2. Without same-origin policy, that hacker website could make authenticated malicious AJAX calls to https://examplebank.com/api to POST /withdraw even though the hacker website doesn’t have direct access to the bank’s cookies.

      Cross-domain vulnerability

    1. pitfalls with PurgeCSS, like it won't actually render your components to check dynamic class usage, so you want to avoid partial class names in dynamic renders and instead stick to full class names

      dynamic class names are an edgecase of purgecss

    2. PurgeCSS which will parse any files that match the given file globs for the usage of the selectors in your CSS. If a selector isn't present in any of the matched files, then it rips those styles out of the CSS, ultimately slimming the build.

      Slimming CSS builds using PurgeCSS

    1. central service registry

      discovery of microservices, orchestration

    2. minimizing latency and enabling event-driven interactions with applications.

      async communication, AMQP, advanced message queuing protoal

    3. commonly used libraries and SDKs can be moved to a dedicated service that can be managed independently, making the service immutable.

      CI/CD pipeline considerations when deps are shared, with the risk of breaking services

    1. Often our efforts don’t “immediately translate into desired organizational outcomes.” In other words, “you could be doing all the right things but, unfortunately, it’s taking a long time for it to lead to positive results.”

      Being more results oriented.

    2. It’s normal to underperform on occasion. After all, everyone has an off quarter — or even an off year — from time to time.

      Underperformance happens

    1. When a React component dispatches actions, how can another service catch the actions, accumulate and group them, then redispatch a single action?

      Catching actions to accumulate and group them

  13. Mar 2020
    1. “undefined as a value” and “undefined as a type” are both written as undefined. Depending on where you use it, it is interpreted as a value or as a type. The same is true for null.

      Depending on location, undefined is interpreted as a value or as a type.

    1. Tuple types allow you to express an array where the type of a fixed number of elements is known

      Typescript tuples

    2. Currying is the process of transforming a function that takes multiple arguments into a series of functions that take one argument at a time

      Currying theory

    1. They are strangers in the room and I don’t even recall their names, so how can I begin to trust them? The answer is damn simple: start writing tests from day 1!

      Automated testing eases comfort working with new tech

    2. Senior Developer or Tech Lead, or Software Architect, then you probably recall that your career path had multiple rounds of specializing on different technologies and tools within one domain.

      The path of a Senior Developer has multiple rounds of specialization

    3. additional layers of complexity and dependency on many third party providers

      Don't get lost in never ending learning curve

    1. Jupytext can be configured to automatically pair a git-friendly file for input data while preserving the output data in the .ipynb file

      git-friendly Jupytext options include

      • Julia: .jl
      • Python: .py
      • R: .R
      • Markdown: .md
      • RMarkdown: .Rmd
      • and more!
    1. different problems that are sufficiently similar that you can apply a same model to them, but sufficiently different that this model has to be customized considerably to be applicable in each case.

      Equivalent Problems

    1. In your Python interpreter, enter import this and you will see "The Zen of Python". Python generally encourages code to be written in the most obvious way possible. Ideally, all code should be written in one way - the community doesn't think it should be in a Functional style.

      Easter egg in your Python interpreter

    2. He discussed the history of Functional Programming language features in one of his blog posts. As a result, the language implementations have not been optimized for Functional Programming features.

      The creator of Python, Guido van Rossum, did not intend for Python to have functional features but did appreciate some of the benefits its introduction has brought to the language

    3. Every map and filter expression can be expressed as a list comprehension.

      Python includes HOF to make processing iterable objects like lists and iterators much easier.

    4. Ever had a bug where you wondered how a variable you set to 25 became None? If that variable was immutable, the error would have been thrown where the variable was being changed, not where the changed value already affected the software - the root cause of the bug can be found earlier.

      Immutability. While we can change the contents of a mutable object in a Tuple, we cannot change the reference to the mutable object that's stored in memory.

    1. Every useState() call gets its own “memory cell”.

      Hooks proposal relies on call order, isolating multiple name state variables from each other.

    2. point of supporting multiple useState() calls is so that you can extract parts of stateful logic (state + effects) out of your components into custom Hooks which can also independently use local state and effects

      Reasons to avoid managing state via a single object instead of discrete state variables

    3. array destructuring syntax to name useState() state variables but these names are not passed to React. Instead, in this example React treats name as “the first state variable”, surname as “the second state variable”, and so on. Their call index is what gives them a stable identity between re-renders

      Stable identity of useState variables between re-renders

  14. Jan 2020
    1. Unless blank=False is set on the field along with a default then a label containing "---------" will be rendered with the select box.

      Seems like setting blank=True tells Django to allow a TextField to be set to an empty string (even if it is not one of the choices)

  15. Dec 2019
    1. The foundation of GraphQL is its type system. There are basic types like String and Integer and there are complex types that have named attributes.

      Type system is the foundation of GraphQL

    1. Dependency Injection, in its basic form of passing functions into components, keeps things testable, and visualizable in tools like Storybook.

      Testability via dependency injection

    2. make stylable all of the visual states of your application - no clicking around required - just jump right to the state

      Storybook value proposition: state inventory without requiring interactions

    3. The easy, functional-programming concept that a component can receive both functions AND data as arguments

      Injecting a function, a fp concept, to enable testing

    4. in React, the component doesn't encapsulate completely around the lookup method. It provides a default implementation but allows its environment to override it

      React functional component receives method to enable testing

  16. Nov 2019
    1. What happens when multiple components in the same app want the same data? With the current implementation, each component would have to refetch data from the server. We will try to improve our implementation to handle caching and concurrent access to the same asynchronous data store.

      Caching and request de-duplication for multiple components that request the same data

    1. if you’re building for both browsers and Node.js since you’ll have to bundle a build for browsers as well

      Babel and source maps, do we still need them?

    2. One of the more confrontational parts of JavaScript development has always been its module system
    3. What once began as a humble side project on Reddit, which you can see here, has now grown so much that it has fundamentally transformed how we build and develop Node.js applications.
    1. whenever there's a lot going on, computers (but mostly humans) will get stuff wrong. In the 6 lines of our component, rendering 2 node types, we change syntaxes from JS to JSX, and back, 8 times! Count them - it's like JS(JSX(JS(JSX(JS))))! This is not the simplest code we can write.

      render() {

        { languages.map(item => (
      • {item}
      • )) }

    1. REST_FRAMEWORK = { 'DEFAULT_PAGINATION_CLASS': 'rest_framework.pagination.LimitOffsetPagination', 'PAGE_SIZE': 100 }
    1. define an object inside your React function component, it is not going to be referentially equal to the last time that same object was defined (even if it has all the same properties with all the same values)

      Referential equality in React