902 Matching Annotations
  1. Sep 2020
    1. The difference between default and named affects how other people can consume your bundle. If you use default, a CommonJS user could do this, for example:

      include the following content

    1. Proving to myself that isValid does correctly change to true even when a key in $errors is an array.

    1. Child can't update things by reassignment if you do:

      <Child bind:things={things} />
      

      but can if you do;

      <Child bind:things={$object.things} />
      
    1. Demonstrates that even though object.value kind of works, it will be out of date. You need to subscribe to it to get current value: $object.value

    1. "The First Amendment and Supreme Court decisions protect the news media in their reporting on matters of public interest, so you really have to show actual malice and disregard for the truth that would be very blatant and very provable," said Gene Policinski, senior vice president of the First Amendment Center.

      https://web.archive.org/web/20200901145543/https://www.freedomforuminstitute.org/first-amendment-center/

      Our mission: providing resources to help the public understand how their First Amendment freedoms of speech, press, religion, assembly and petition work, and how they can be protected.

      FIRST AMENDMENT EXPERTS The First Amendment Center’s nationally recognized experts David Hudson, Lata Nott, and Gene Policinski regularly provide the media with information and commentary on First Amendment and free expression issues. Interested in contacting one of our experts? Please email media@newseum.org or call 202/292-6200.

    1. For example, you might want to use the browser’s knowledge of the user’s current time zone to group a collection of elements by date.
    1. If you can't understand where it's coming from in the stack traces, please post screenshots or create reproducing sandboxes and we'll try to help. Most of these are probably coming from a few libraries, so the most productive thing to do is to reduce these cases and then file issues with those libraries.
  2. Aug 2020
    1. select some text

      this is an example of annotation.

      If you wish, you can add images, videos, or links.

      To add tags, type in the bow below and press Enter.

    1. This illustrates the difference between two types of scrolling:

      • scrolling within the dialog
      • scrolling the document that includes the dialog
    1. Corporate social media has been dominating the online space so significantly that the newest generation of Internet users now thinks that is what the "web" actually is. Fortunately, with WordPress as your platform, you can not only take back your online identity and presence, but you can use it to have a richer and fuller experience than the locked-down experience you get with the limits of Facebook, Twitter, Instagram, etc.

      make a note

    1. But it's easy to imagine that the caption was incorrect for too long because those who know the language, know where the mistake is, and those who don't, think that it's the correct way to spell it.

      those who know the language, know where the mistake is, In other words, they can easily spot the mistake and no better than to repeat it themselves, but either are powerless or too lazy to actually fix it on SE.

      and those who don't, think that it's the correct way to spell it. So those who should no better are inadvertently perpetuating the mistake and teaching others that it is an acceptable/correct usage.

    2. Can't upvote this enough. It is highly irritating to see language destroyed (and we wonder why kids bastardize the language..).
    1. proscriptive, nonprescriptive

      Interesting how a word can have multiple antonyms/opposites that are "opposite" in different ways/senses:

      • proscriptive: forbid rather than prescribe
      • nonprescriptive: absence of prescribing
    1. Perhaps someone should give an example of when 'into' is ever correct. "Turn into bed" is definitely incorrect, unless one is morphing into the form of a bed. But what about "he fell into the hole", "she went into the house", or "Star Trek Into Darkness"?
    1. For example, the word dog describes both the species Canis familiaris and male individuals of Canis familiaris, so it is possible to say "That dog isn't a dog, it's a bitch" ("That hypernym Z isn't a hyponym Z, it's a hyponym Y").
  3. Jul 2020
    1. When downloading a lifestyle mobile app, the app asks for consent to access the phone’saccelerometer. This is not necessary for the app to work, but it is useful for the controller who wishesto learn more about the movements and activity levels of its users. When the user later revokes thatconsent, she finds out that the app now only works to a limited extent. This is an example of detrimentas meant in Recital 42, which means that consent was never validly obtained (and thus, the controllerneeds to delete all personal data about users’ movements collected this way).
  4. Jun 2020
    1. For example, if error messages in two narrowly defined classes behave in the same way, the classes can be easily combined. But if some messages in a broad class behave differently, every object in the class must be examined before the class can be split. This illustrates the principle that "splits can be lumped more easily than lumps can be split".
    1. An example candidate for caching might be a nightly billing task which aggregates billing data for the past month. That kind of task is likely not expecting last minute updates while it runs. It assumes that the state of the world remains constant while processing.
    1. including Oracle (since 1984 [4]), Postgres(since 1985 [41]), and MySQL’s InnoDB engine (since 2001). Butwhile there are plenty of contemporaries to these older systemsthat use a single-version scheme (e.g., IBM DB2, Sybase), almostevery new transactional DBMS eschews this approach in favor ofMVCC [37]. This includes both commercial (e.g., Microsoft Heka-ton [16], SAP HANA [40], MemSQL [1], NuoDB [3]) and academic(e.g., HYRISE [21], HyPer [36]) systems
  5. May 2020
    1. of, relating to, or being a grammatical case or form expressing means or agency

      I really need an example of this!

      It seems unusual that they specifically mention "a grammatical case or form". I've never seen a definition before that is anything like this one.

      How is this different from definition 1?

    1. sadness.js will not load, however, as document.write() produces script elements which are "parser-inserted".
  6. developer.chrome.com developer.chrome.com
    1. If a user clicks on that button, the onclick script will not execute. This is because the script did not immediately execute and code not interpreted until the click event occurs is not considered part of the content script, so the CSP of the page (not of the extension) restricts its behavior. And since that CSP does not specify unsafe-inline, the inline event handler is blocked.
    1. This change was made because GitLab License Management is now renamed to GitLab License Compliance. After review with users and analysts, we determined that this new name better indicates what the feature is for, aligns with existing market terminology, and reduces confusion with GitLab subscription licensing features.
    1. $10 donation = $9.41 deposited into your bank account the next business day $100 donation = $96.80 deposited into your bank account the next business day
    1. In algebra, for some set S together with an operation ⋆ {\displaystyle \star } to form a group, it is necessary that ⋆ {\displaystyle \star } be associative.

      Seems like a simpler example (of individually necessary and jointly sufficient) that is easier to follow could be found.

    2. that a number x {\displaystyle x} is rational (S) is sufficient but not necessary to x {\displaystyle x} being a real number (N) (since there are real numbers that are not rational)
    3. being a male is a necessary condition for being a brother, but it is not sufficient—while being a male sibling is a necessary and sufficient condition for being a brother
    4. in order for human beings to live, it is necessary that they have air
    1. This does not have to be an additional form. In practice, you can simply add several checkboxes informing the user of each additional purpose and allowing them to give consent specific to those cases.

      See the images above, which are a good example of how to do it and how not to do it.

    1. By itself the name John Smith may not always be personal data because there are many individuals with that name. However, where the name is combined with other information (such as an address, a place of work, or a telephone number) this will usually be sufficient to clearly identify one individual.
    2. Simply because you do not know the name of an individual does not mean you cannot identify that individual. Many of us do not know the names of all our neighbours, but we are still able to identify them.
    1. If you’re selling products and keep record of users’ choices for marketing purposes, dividing them into meaningful categories, such as by age, gender, geographical origin etc., you’re profiling them.
  7. Apr 2020
    1. purposes are grouped into 5 categories (strictly necessary, basic interactions & functionalities, experience enhancement, measurement, targeting & advertising)
    2. Strictly necessary (id 1). Purposes included:Backup saving and managementHosting and backend infrastructureManaging landing and invitation pagesPlatform services and hostingSPAM protectionTraffic optimization and distributionInfrastructure monitoringHandling payments
    1. In informal contexts, mathematicians often use the word modulo (or simply "mod") for similar purposes, as in "modulo isomorphism".
    1. In December 2006, 34,000 actual user names and passwords were stolen in a MySpace phishing attack. The idea of the attack was to create a profile page named "login_home_index_html", so the URL looked very convincing. Specially-crafted HTML and CSS was used to hide the genuine MySpace content from the page and instead display its own login form.
    1. If you don't—or can't—lock your users in, the best way to compete is to innovate at a breakneck pace. Let's use Google Search as an example. It's a product that cannot lock users in: users don't have to install software to use it; they don't have to upload data to use it; they don't have to sign two-year contracts; and if they decide to try another search engine, they merely type it into their browser's location bar, and they're off and running.
    1. A simple, complete Chrome extension which injects a content script to click the button with id="product-addtocart-button" when you click on a browser_action button would be
    1. The handler can be a method or a Proc object passed to the :with option. You can also use a block directly instead of an explicit Proc object.

      Example of: letting you either pass a proc (as a keyword arg in this case) or as a block.

  8. Mar 2020
    1. The phrase is often used at the beginning of meetings, conferences, etc to indicate that the speaker is going to tell those present about the fire exits, where the toilets, first-aid box etc are and any other administrative issues that have nothing to do with the actual content of the meeting. etc
  9. Feb 2020
  10. Dec 2019
    1. Feed iguana +Personal @Home (A) Ask doctor about ticks +Personal @DoctorsOffice Write elephant touchscreen post +HowToGeek @Home @Laptop (B) Research laptop prices +Personal @Home @Laptop (C) Clean the damn kitchen +Personal +Cleaning @Home
    1. if 𝑛nn does not divide 𝑚mm evenly, then the answer is the greatest common divisor of 𝑛nn and the remainder of 𝑚mm divided by 𝑛nn.

      m = 20, n = 10 20 / 10 = 2 CASE 1

      m = 100, n = 70 100 / 70 CASE 2 gcd(100, 100 % 70) =

      gcd(100, 30) gcd(100,30) CASE 2 gcd(100, 100 % 30) =

      gcd(100, 10) 100 / 10 = 10 CASE 1

      gcd(100, 70) = 10

  11. Nov 2019
    1. const setRefs = useRef(new Map()).current; const { children } = props; return ( <div> {React.Children.map(children, child => { return React.cloneElement(child, { // v not innerRef ref: node => { console.log('imHere'); return !node ? setRefs.delete(child.key) : setRefs.set(child.key, node)

      Illustrates the importance of having unique keys when iterating over children, since that allows them to be used as unique keys in a Map.

    2. useRef(new Map()).current
    1. Since an uncontrolled component keeps the source of truth in the DOM, it is sometimes easier to integrate React and non-React code when using uncontrolled components.

      A good example for when to use uncontrolled components

    1. Tests implementation details a bit (child component props received), but pretty good other than that.

      https://www.robinwieruch.de/react-testing-tutorial, for example, says that is reasonable to do:

      an integration test could verify that all necessary props are passed through from the tested component to a specific child component.

    1. Using expect { }.not_to raise_error(SpecificErrorClass) risks false positives, as literally any other error would cause the expectation to pass, including those raised by Ruby (e.g. NoMethodError, NameError, and ArgumentError)

      Actually, those would be false negatives: the absence of a test failure when it should be there.

      https://en.wikipedia.org/wiki/False_positives_and_false_negatives

    1. This is called a false positive. It means that we didn't get a test failure, but we should have

      No, this is a false negative. We didn't get a test failure (that is, there is a lack of the condition (test failure)), when the condition (test failure) should have been present.

      Read https://en.wikipedia.org/wiki/False_positives_and_false_negatives

  12. Oct 2019
    1. the branching timeline in Charles Renouvier’s 1876 Uchronia (Utopia in History): An Apocryphal Sketch of the Development of European Civilization Not as It Was But as It Might Have Been, depicting both the actual course of history and the various alternative paths that might have been if other actions had been taken.

      example of successful multiple timeline paths

    1. type FindByTag<Union, Tag> = Union extends { tag: Tag } ? Union : never; function cast<A extends Foo["tag"]>(foo: Foo, expectedTag: A): FindByTag<Foo, A> { if (foo.tag !== expectedTag) throw Error(`expected tag ${expectedTag} but was ${foo.tag}`) return foo as FindByTag<Foo, A>; }
    1. type Type = 'a' | 'b'; type AShape = { a: 'a' }; type BShape = { b: 'b' }; type Props<T extends Type> = { type: T, shape: T extends 'a' ? AShape : BShape, }; class Test<T extends ID> extends React.Component<Props<T>> { render() { const { type, shape } = this.props; switch (type) { case 'a': return <>{shape.a}</>; // Ideally would narrow `shape` here, instead of `AShape | BShape` default: return <>{shape.b}</>; } } } <T type="a" shape={{ a: 'a' }} /> // No error in ideal case <T type="a" shape={{ b: 'b' }} /> // error in ideal case
    2. type NumberType = (() => number) | number; function double<T extends NumberType>( num: T ) : T { if (typeof num === "number") return num * 2; return () => num() * 2; }
  13. Sep 2019
    1. This is a ”stale closure”. I won’t get into closures, but just know that because of the implementation of React/hooks, the count variable is always going to be 0 in our interval function. It’s an old reference.
    1. It is also possible to use this annotator to annotate fields other than the NamedEntityTagAnnotation field by and providing the header

      Zrejme sa jedná o možnosť anotovať aj iné ako NER tagy, že to TokensRegex umožňuje. Nižšie mi chýba príklad presne na toto.

    1. The Executive [Lincoln] is frequently compelled to affix his signature to bills of the highest importance, much of which he regards as wholly at war with the national interests.
  14. Aug 2019
    1. const useFocus = () => { const htmlElRef = useRef(null) const setFocus = () => {htmlElRef.current && htmlElRef.current.focus()} return [ setFocus, htmlElRef ] }

      exampleOf: useRef exampleOf: custom hook

    1. However, using the local storage in React's function components is a side-effect which is best implemented with the Effect Hook which runs every time the value property changes:
    1. I was so fed up of the mega amounts of boilerplate with Redux and the recommendation of keeping your data loading at view level. It seems to me that things like this, with components being responsible for their own data, is the way to go in the future.
    1. Demonstrates how label text will wrap at a point that appears to narrow when shrunk (the label can't even be as wide as the input it is labeling!), and how to work around this problem by adding styles:

        '& label': {
          whiteSpace: 'nowrap'
        }
      

      Of course, you would only want to do this if you are going to only be showing the label in shrunk state (which I think is safe to say is the case for date picker inputs), since it would look bad to actually have text overflowing outside of the input box. But if it's in "shrink" state, then it's actually above the input, so as long as there isn't another input/label directly to the right, and/or as long as we adjust the width so the right side of the label mostly lines up with the right side of the input, then I think we should be safe.

      Reference

      The input label "shrink" state isn't always correct. The input label is supposed to shrink as soon as the input is displaying something. In some circumstances, we can't determine the "shrink" state (number input, datetime input, Stripe input). You might notice an overlap.

      To workaround the issue, you can force the "shrink" state of the label.

      You need to make sure that the input is larger than the label to display correctly.

  15. Jul 2019
    1. Kahle has been critical of Google's book digitization, especially of Google's exclusivity in restricting other search engines' digital access to the books they archive. In a 2011 talk Kahle described Google's 'snippet' feature as a means of tip-toeing around copyright issues, and expressed his frustration with the lack of a decent loaning system for digital materials. He said the digital transition has moved from local control to central control, non-profit to for-profit, diverse to homogeneous, and from "ruled by law" to "ruled by contract". Kahle stated that even public-domain material published before 1923, and not bound by copyright law, is still bound by Google's contracts and requires permission to be distributed or copied. Kahle reasoned that this trend has emerged for a number of reasons: distribution of information favoring centralization, the economic cost of digitizing books, the issue of library staff without the technical knowledge to build these services, and the decision of the administrators to outsource information services
    1. A practical example of service design thinking can be found at the Myyrmanni shopping mall in Vantaa, Finland. The management attempted to improve the customer flow to the second floor as there were queues at the landscape lifts and the KONE steel car lifts were ignored. To improve customer flow to the second floor of the mall (2010) Kone Lifts implemented their 'People Flow' Service Design Thinking by turning the Elevators into a Hall of Fame for the 'Incredibles' comic strip characters. Making their Elevators more attractive to the public solved the people flow problem. This case of service design thinking by Kone Elevator Company is used in literature as an example of extending products into services.
    1. Unfortunately, misguided views about usability still cause significant damage in today's world. In the 2000 U.S. elections, poor ballot design led thousands of voters in Palm Beach, Florida to vote for the wrong candidate, thus turning the tide of the entire presidential election. At the time, some observers made the ignorant claim that voters who could not understand the Palm Beach butterfly ballot were not bright enough to vote. I wonder if people who made such claims have never made the frustrating "mistake" of trying to pull open a door that requires pushing. Usability experts see this kind of problem as an error in the design of the door, rather than a problem with the person trying to leave the room.
    1. Other examples of complex adaptive systems are:stock markets: Many traders make decisions on the information known to them and their individual expectations about future movements of the market. They may start selling when they see the prices are going down (because other traders are selling). Such herding behavior can lead to high volatility on stock markets. immune systems: Immune systems consist of various mechanisms, including a large population of lymphocytes that detect and destroy pathogens and other intruders in the body. The immune systems needs to be able to detect new pathogens for the host to survive and therefore needs to be able to adapt.brains: The neural system in the brain consists of many neurons that are exchanging information. The interactions of many neurons make it possible for me to write this sentence and ponder the meaning of life. ecosystems: Ecosystems consist of many species that interact by eating other species, distributing nutrients, and pollinating plants. Ecosystems can be seen as complex food webs that are able to cope with changes in the number of certain species, and adapt – to a certain extent – to changes in climate. human societies: When you buy this new iPhone that is manufactured in China, with materials derived from African soils, and with software developed by programmers from India, you need to realize that those actions are made by autonomous organizations, firms and individuals. These many individual actions are guided by rules and agreements we have developed, but there is no ruler who can control these interactions.
  16. Jun 2019
    1. Pliny the Elder (died 79 A.D.) wrote a massive work called The Natural History in 37 Books. It was a kind of encyclopedia that comprised information on a wide range of subjects. In order to make it a bit more user friendly, the entire first book of the work is nothing more than a gigantic table of contents in which he lists, book by book, the various subjects discussed. He even appended to each list of items for each book his list of Greek and Roman authors used in compiling the information for that book. He indicates in the very end of his preface to the entire work that this practice was first employed in Latin literature by Valerius Soranus, who lived during the last part of the second century B.C. and the first part of the first century B.C. Pliny's statement that Soranus was the first in Latin literature to do this indicates that it must have already been practiced by Greek writers.
  17. May 2019
    1. his is the second round of mineral licensing conducted by the Afghan government, which in 2008 gave Metallurgical Corp of China rights to the Aynak copper deposit

      They seem to offer up mining contracts very easily.

    1. Elodie is 15. Her two-month-old son is wrapped tightly in a frayed cloth around her back. He inhales potentially lethal mineral dust every time he takes a breath. Toxicity assaults at every turn; earth and water are contaminated with industrial runoff, and the air is brown with noxious haze. Elodie is on her own here, orphaned by cobalt mines that took both her parents. She spends the entire day bent over, digging with a small shovel to gather enough cobalt-containing heterogenite stone to rinse at nearby Lake Malo to fill one sack. It will take her an entire day to do so, after which Chinese traders will pay her about $0.65 (50p). Hopeless though it may be, it is her and her child’s only means of survival.
  18. Apr 2019
    1. Welcome to the continually updated CBS Local Daily Story Stream. Here’s a look at the top stories people are talking about now across our network of CBS Local sites
    1. An attractive Interface for browsing and reading Wikibase information

      blog post with feature requirements and story for improved wikibase interface. Talks about reasonator

  19. Mar 2019
    1. Fortunately, we are starting to see campaigns related to the destigmatization of mental illness and an increase in public education and awareness. Join the effort by encouraging and supporting those around you to seek help if they need it. To learn more, visit the National Alliance on Mental Illness (NAMI) website (http://www.nami.org/). The nation’s largest nonprofit mental health advocacy and support organization is NAMI.

      Another way of de-stigmatizing mental illness is by offering training for people so that they can react to mental illnesses and also educate their peers about the reality of it. WSU is doing this through their mental health training program, which can be found here. https://cougarhealth.wsu.edu/mental-health-promotion/mental-health-trainings/

    2. Virginia, and Columbia University, interviews with over 1,300 U.S. adults show that they believe children with depression are prone to violence and that if a child receives treatment for a psychological disorder, then that child is more likely to be rejected by peers at school.

      Many resources are available for most university students, for example, WSU offers behavioral health services for an incredibly large number of different mental problems from anxiety and depression to phobias and insomnia. One might argue however that high school campuses don't offer enough treatment or do enough to de-stigmatize mental illnesses, especially in the wake of catastrophes like sandy hook among others.

    1. Linear perspective

      To get an idea of how the linear perspective works, imagine looking at a painting of a big city. As the buildings get smaller, the distance appears to be further away. This is because we see two parallel lines begin to converge on each other. This is just one of the ways we use monocular cues.

    2. depth perception

      Have you ever tried throwing an object at someone? In order to hit the other person, you had to determine the distance from yourself to the target. Part of being able to perceive things in a 3D world involves gauging distance. This is one of the ways we use our depth perception.

  20. Feb 2019
    1. In a 2011 Reddit IAmA, Jennings recalled how in 2004 the Democratic politicians Chuck Schumer and Harry Reid unsuccessfully asked Jennings to run for the United States Senate from Utah. Jennings commented, "That was when I realized the Democratic Party was f@#$ed in '04."[19]
    1. [First published in 1726–7.]

      To: Philbert

      Example question: When was Gulliver's Travels first published? a) 1776 b) 1726 c) 1830 d) 1945

    1. practical,

      A form of practical intelligence at Washington State University might show itself at a social function on the weekend. Say you are at your house and you notice one of your friends is stumbling and not speaking clearly. You sit them down and have the option to hand them two beverages; one beverage is a light beer, the other is a glass of water. A person that shows practical intelligence also known as street smarts or common sense would choose the glass of water, having realized their friend is probably too drunk. A person lacking practical intelligence would hand them the light beer, this would lead to a worse situation for your friend and in turn yourself, because then you would have to take care of your friend in an even worse shape then they were when you first saw them.

    2. analytical

      An example of analytical intelligence that is measured at Washington State University is done through the use of exams. Depending on the type of exam you are faced with you may have to compute numbers, either by plugging number into an equation or doing the proper order of operations on a set of numbers. Other exams might have you problem solving with a theoretical scenario, such as one that you might face in ethics. Say you are faced with a multiple choice question with four options of which only one is correct. You have no idea what the answer to the question is after reading it. You then realize that two of the options are basically saying the same thing, therefore neither can be the answer. You then move on to the next answer, you realize this answer has nothing to do with the problem. You have now established the only answer that even has a possibility of being correct. This example is analytical intelligence.