676 Matching Annotations
  1. Last 7 days
    1. the best known example of this type of research concerns the co-evolution of pastoralism and lactose tolerance [30]. In rough terms, the basic hypothesis—which is widely accepted and well confirmed—is that the adoption of dairying set up a modified niche in which the ability to digest lactose into adulthood was at an advantage.

      Best known example of gene-culture coevolution - co-evolution of pastoralism and lactose intolerance - the adoption of dairying set up a modified niche - in which the ability to digest lactose into adulthood was an advantage. - ancestors who were lactose tolerant could take advantage of a new source of calories. - Hence it is the learned acquisition of dairying which explains the natural selection of genes favoring lactase persistence, - the continued production of the enzyme lactase beyond weaning - Dual inheritance theory (Gene-culture coevolution) typically uses this example to explain - Dairying is inherited via a cultural channel - lactase persistence is inherited via a genetic channel - Recent supporters of this also make recent claims that it is not possible to distinguish between - what is biological from what is cultural

    1. You can also find the combination verb+in+to, but in that case you're usually dealing with a phrasal verb consisting of a verb and the particle "in", which happens to be followed by the preposition "to".They wouldn't give in to our demands.
    2. "Built in to" appears when you use the phrasal verb "build in" followed by an infinitive, but that is not what you are trying to do in your sentence.There's an electronic switch built in to stop all data transfers.
  2. Mar 2023
    1. Preserving ecosystem area is sometimes critiqued as ‘fortress conservation’ by environmental justice scholars, limiting access for poor or Indigenous people68. An ecosystem area boundary therefore requires careful consideration and involvement of the local communities, for example by not demanding that intact areas preclude human inhabitation and sustainable use and/or recognizing the role of Indigenous peoples and local communities in already protecting these areas.
      • Comment
      • "Fortress conservation" is an example of approaching safe boundaries but not considering JUST boundaries.
  3. Feb 2023
    1. The Dick and Carey model

      I like how this model establishes the goals to support the design and revise the process by identifying behaviors and objectives.

    1. Zettelkasten example using my preferred toolchain.

      Possibly the quickest way to get the technique under your fingers by browsing the author's example.

    1. The appendix of the 2nd edition (PDF)

      This is interesting, but I'd also like to see examples of how permanent notes evolve from their associated fleeting and literature notes.

  4. Jan 2023
    1. ProPublica recently reported that breathing machines purchased by people with sleep apnea are secretly sending usage data to health insurers, where the information can be used to justify reduced insurance payments.

      !- surveillance capitalism : example- - Propublica reported breathing machines for sleep apnea secretly send data to insurance companies

    1. class String alias strip_ws strip def strip chr=nil return self.strip_ws if chr.nil? self.gsub /^[#{Regexp.escape(chr)}]*|[#{Regexp.escape(chr)}]*$/, '' end end
  5. Dec 2022
    1. cultural evolution can lead to genetic evolution. "The classic example is lactose tolerance," Waring told Live Science. "Drinking cow's milk began as a cultural trait that then drove the [genetic] evolution of a group of humans." In that case, cultural change preceded genetic change, not the other way around. 

      !- example of : cultural evolution leading to genetic evolution - lactose intolerance

    1. Now picture Timothy, who lives with his grandchildren in Walande Island, a small dot of land off the east coast of South Malaita Island, part of the Solomon Islands. Since 2002, the 1,200 inhabitants of Walande have abandoned their homes and moved away from the island. Only one house remains: Timothy’s. When his former neighbors are asked about Timothy’s motives they shrug indifferently. “He’s stubborn,” one says. “He won’t listen to us,” says another. Every morning his four young grandchildren take the canoe to the mainland, where they go to school, while Timothy spends the day adding rocks to the wall around his house, trying to hold off the water for a bit longer. “If I move to the mainland, I can’t see anything through the trees. I won’t even see the water. I want to have this spot where I can look around me. Because I’m part of this place,” he says. His is a story that powerfully conveys the loneliness and loss that 1.1 degrees of anthropogenic warming is already causing. 

      !- example : storytelling to save the earth

    1. I quickly found myself in the ironic situation of spending so much time building a tool to help with my schoolwork that I stopped actually doing my schoolwork.

      Early example of being overwhelmed by one's tool.

  6. Nov 2022
    1. It can be useful to use with keywords argument, which required symbol keys.
    1. v5: added git and github (thanks @ceejbot), and RSS (thanks @zem42). Taking suggestions for hierarchical/distributed and hierarchical/decentralized.

      t Laurie Voss's crowdsourced set of examples of things that have structure & control in the form of the following: - centralized - hierarchical - federated - distributed - decentralized

      Picture below: Link to tweet: https://twitter.com/seldo/status/1486563446099300359?s=20&t=C6z9xUF_YBkOFmfcjfjpUA

    1. Throughout this piece Oppenheimer provides examples of notes he wrote which eventually made it into his written output in their entirety.

      This has generally been uncommon in the literature, but is a great form of pedagogy. It's subtle, but it makes his examples and advice much stronger than others who write these sorts of essays.

    1. Let's look at a concrete example. Suppose that your container contains a web server that runs a CGI script that's written in bash. The CGI script calls grep. Then the web server decides that the CGI script is taking too long and kills the script, but grep is not affected and keeps running. When grep finishes, it becomes a zombie and is adopted by the PID 1 (the web server). The web server doesn't know about grep, so it doesn't reap it, and the grep zombie stays in the system.
    1. Consider a text file containing the German word für (meaning 'for') in the ISO-8859-1 encoding (0x66 0xFC 0x72). This file is now opened with a text editor that assumes the input is UTF-8. The first and last byte are valid UTF-8 encodings of ASCII, but the middle byte (0xFC) is not a valid byte in UTF-8. Therefore, a text editor could replace this byte with the replacement character symbol to produce a valid string of Unicode code points. The whole string now displays like this: "f�r".
    1. A glyph can also represent more than one character at once. Take an f_f_f ligature as an example. It represents three f characters in a row. Ligatures do not have Unicodes, because the separate characters already have codes and the the fact that it’s a ligature does not change the meaning of its parts.
  7. Oct 2022
    1. Test.new.test { puts "Hi!" }
    2. You cannot use yield inside a define_method block. This is because blocks are captured by closures, observe: def hello define_singleton_method(:bye) { yield } end hello { puts "hello!" } bye { puts "bye!" } #=> "hello!"
    1. grammar Parser { rule TOP { I <love> <lang> } token love { '♥' | love } token lang { < Raku Perl Rust Go Python Ruby > } } say Parser.parse: 'I ♥ Raku'; # OUTPUT: 「I ♥ Raku」 love => 「♥」 lang => 「Raku」 say Parser.parse: 'I love Perl'; # OUTPUT: 「I love Perl」 love => 「love」 lang => 「Perl」
    1. With email, if you change your provider then your email address has to change too.


      I don't know why they wrote this; they know this isn't true. It's not just a case of me being a stickler/pedant. This example should have simply never been used.

    1. def initialize_copy(original_animal) self.age = 0 super end def initialize_dup(original_animal) self.dna = generate_dna self.name = "A new name" super end def initialize_clone(original_animal) self.name = "#{original_animal.name} 2" super end
  8. Sep 2022
    1. I don't know about you guys but I like dots on the second line when combined with indentation : # Example 1 one.two.three .four # Example 2 my_array.select { |str| str.size > 5 } .map { |str| str.downcase }
    1. Samsung,Company


    2. akemyfriendRandy,forexample.


    3. 1am bombarded with catchy commer-cials, communication catalogs, and peoplewho are trying to convince me all of thistechno stuff is inevitable, a sign of the times,the way of the world.

      Anecdote ish?

    4. BlackBerry, Razr, and Firefly.


    5. A jogger runs down the Leelanau Trailtalking on a cell phone. A student text-messages while in class. High-speed. Real-time. BlackBerry, Razr, and Firefly.

      Scenario, anecdote?

    1. between an orange juice blender (a juice blender that’s orange) and an orange-juice blender (a blender that makes juice from oranges)
    2.   high school kids vs. high-school kids (school kids on pot, or kids in high school)   one armed bandit vs. one-armed bandit (an armed bandit alone, or a bandit with one arm)   criminal law professors vs. criminal-law professors   small animal veterinarian vs. small-animal veterinarian   old boat dealer vs. old-boat dealer   bad weather report vs. bad-weather report   big business owner vs. big-business owner
  9. Aug 2022
  10. Jul 2022
    1. another way to put this is um that if you think about using a telescope an example that alan offered us a little while ago to examine celestial objects as indeed did 00:20:37 galileo you can only interpret the output of that telescope the things you see in the telescope correctly if we actually know how it works that's really obviously true about 00:20:48 things like radio telescopes and infrared telescopes but it's true of optical telescopes as well as paul fire opened emphasized if you don't have a theory of optics then when you aim your telescope at jupiter and look at the 00:21:00 moons all you see are bits of light on a piece of glass you need to believe to know how the telescope works in order to understand those as moons orbiting a planet 00:21:12 so to put it crudely if we don't know how the instrument that we're using uh if we don't know how the instrument that we're using to mediate our access to the world works if we don't understand it we don't know whether we're looking through 00:21:24 a great telescope or a kaleidoscope and we don't know whether we're using a pre a properly constructed radio telescope or just playing a fantasy video game

      Good example of how astronomers must know the physical characteristics of the instrument they use to see the heavens, a telescope before anything they observe be useful. The same is true when peering into a microscope.

      The instrument of our bodies faculties is just as important to understand if we are to understand the signals we experience.

    1. to bring it to the present you know the news cycle is about russia and ukraine yeah there are propositional things there about what's the capital of 00:01:15 russia what's the capital of ukraine where's the border then you have sort of procedural um how how do you discuss this matter or or how do we make decisions about this what are the things in play and then you have 00:01:27 um question perspective like how does it look in moscow how does it look in kiev how does it look at the u.n yes and then you have something about participation what's it like to be at the border in the east of ukraine for example yeah 00:01:39 yeah what identities are you assigning what identities are you are are you assuming what roles right yeah yeah i mean it's not nothing immediately politicized i just mean to bring it to bear that in any given context there are 00:01:52 always these multiple ways of knowing that are a big thing

      Example of applying the 4 P's to something topical at the time of this video: The Russia / Ukraine war.

  11. Jun 2022
    1. This podcast is also available on Spotify, Apple Podcasts and Anchor. Please subscribe on your favoured podcast provider and leave a review.

      There are actually seven different services that this podcaster has done a huge amount of work to put their content on, ostensibly for the widest discovery, but not a single one of them has a link to the raw audio file to make it easy for one to bookmark and listen to later. Apparently the podcasting silo services have managed to win out over the open web.

      Do we really need to make podcasting this hard on individual publishers? Why can't the publisher just have one location and tell all the aggregators, here's a link to my feed, copy it if you will and want to help distribute my content? In some sense, this is part of what is happening as all seven services are using the same findable source, they're just making it more difficult to jump through all the hoops, which means the small guys end up paying more to do the extra work and potentially lose everything if that one source disappears, closes down, or gets acquired and goes away.

      These sorts of artificial hurdles and problems are what make it so hard to get up and running.

    1. What happens in Indonesia when a textile manufacturer illegally dumps dye waste!

      This is an example of the manufacturer / consumer dualism created by the Industrial Revolution. Since manufacturers have become a separate layer that no longer exist as part of the community, as artisans once did, along with globalized capitalism, the consumer does not know the life history of the product being consumed. The sensory bubble limits what a consumer can directly know.

      One answer is to promote a trend back to local and artisan production. Relocalizing production can empower consumers to inspect producers of the products they consume, holding them accountable.

      Another answer is to develop globalized trust networks of producers who are truly ethical.

      Cosmolocal production has networks by the commons nature can promote such values.

  12. May 2022
  13. Apr 2022
    1. Seeing examples of outstanding work motivates students by givingthem a vision of the possible. How can we expect students to produce first-ratework, he asks, when they have no idea what first-rate work looks like?

      Showing students examples of work and processes that they can imitate will fuel their imaginations and capabilities rather than stifle them.

    2. three steps required to solve the all-importantcorrespondence problem. Step one, according to Shenkar: specify one’s ownproblem and identify an analogous problem that has been solved successfully.Step two: rigorously analyze why the solution is successful. Jobs and hisengineers at Apple’s headquarters in Cupertino, California, immediately got towork deconstructing the marvels they’d seen at the Xerox facility. Soon theywere on to the third and most challenging step: identify how one’s owncircumstances differ, then figure out how to adapt the original solution to thenew setting.

      Oded Shenkar's three step process for effective problem solving using imitation: - Step 1. Specify your problem and identify an analogous problem that has been successfully solved. - Step 2. Analyze why the solution was successful. - Step 3. Identify how your problem and circumstances differ from the example problem and figure out how to best and most appropriately adapt the original solution to the new context.

      The last step may be the most difficult.

      The IndieWeb broadly uses the idea of imitation to work on and solve a variety of different web design problems. By focusing on imitation they dramatically decrease the work and effort involved in building a website. The work involved in creating new innovative solutions even in their space has been much harder, but there, they imitate others in breaking the problems down into the smallest constituent parts and getting things working there.

      Link this to the idea of "leading by example".

      Link to "reinventing the wheel" -- the difficulty of innovation can be more clearly seen in the process of people reinventing the wheel for themselves when they might have simply imitated a more refined idea. Searching the state space of potential solutions can be an arduous task.

      Link to "paving cow paths", which is a part of formalizing or crystalizing pre-tested solutions.

    1. if Rails.application.config.reloading_enabled? Rails.autoloaders.main.on_unload("Country") do |klass, _abspath| klass.expire_redis_cache end end
    1. input (32x32x3)max activation: 0.5, min: -0.5max gradient: 1.08696, min: -1.53051Activations:Activation Gradients:Weights:Weight Gradients:conv (32x32x16)filter size 5x5x3, stride 1max activation: 3.75919, min: -4.48241max gradient: 0.36571, min: -0.33032parameters: 16x5x5x3+16 = 1216

      The dimensions of these first two layers are explained here

    1. SELECT lateral_subquery.* FROM posts JOIN LATERAL ( SELECT comments.* FROM comments WHERE (comments.post_id = posts.id) LIMIT 3 ) lateral_subquery ON true WHERE posts.id
    1. Why not add one more category — Personal Wiki — tied to nothing specific, that I can reuse wherever I see fit?

      This is insufficiently explained.

    1. Let's say the user is in the process of selecting some files. The names don't indicate anything. So she has to listen and select.
  14. Mar 2022
    1. his serves as a good example of apt-gets stability. In apt, the name was changed to be more user friendly, while in apt-get the name remains unchanged so as not to break compatibility with old scripts.
  15. Feb 2022
    1. Rather than describing where to go on the Marriott site and what information to plug into the form when I got there, Brian composed a URL that encapsulated that data and transported me into Marriott's app in the right context.
    1. spurred cheating to take on new and different forms.

      Students had the freedom to cheat in the exams, as there was no supervision. It's the courage they get when they have to do their exams online and in their homes.

  16. Jan 2022
    1. export const fibonacci = function (n, initialData) { return readable( { loading: true, error: null, data: initialData, }, (set) => { let controller = new AbortController(); (async () => { try { let result = await fibonacciWorker.calculate(n, { signal: controller.signal }); set({ loading: false, error: null, data: result, }); } catch (err) { // Ignore AbortErrors, they're not unexpected but a feature. // In case of abortion we just keep the loading state because another request is on its way anyway. if (err.name !== 'AbortError') { set({ loading: false, error: err, data: initialData, }); } } })(); return () => { controller.abort(); }; } ); };
    2. <script> import { fibonacci } from './math.js'; $: result = fibonacci(n, 0); </script> <input type=number bind:value={n}> <p>The {n}th Fibonacci number is {$result.data}</p> {#if $result.loading} <p>Show a spinner, add class or whatever you need.</p> <p>You are not limited to the syntax of an #await block. You are free to do whatever you want.</p> {/if}
    1. The most obvious time you'd encounter a 401 error, on the other hand, is when you have not logged in at all, or have provided the incorrect password.
    2. As mentioned in the previous article, the 403 error can result when a user has logged in but they don't have sufficient privileges to access the requested resource. For example, a generic user may be attempting to load an 'admin' route.
    1. You’d like to delete the user, but you’re authenticated as a regular user, not as an admin. The server doesn’t allow regular users to perform such requests, so in the result, the server will send you a 403 error. Re-authentication won’t make any difference.
    1. For example, given a website's normal communication method is the internet, out-of-band communication may be by a voice call.
  17. Dec 2021
    1. For example, one respondent explained that being involvedin a national campaign is beneficial among local members, across the state withother organizations, and with their congressional members who see the organi-zation connected to a larger movement.

      use of an example to explain the operation of a concept.

    2. The field of public health also offers insight aboutthe effectiveness of community-based coalitions for service delivery and theimprovement of health outcomes.

      from public health

    3. “Advocacy Coalition Framework”




  18. Nov 2021
    1. Fixing with containIf we give each article the contain property with a value of content, when new elements are inserted the browser understands it only needs to recalculate the containing element's subtree, and not anything outside it:
    1. Abstract the whole queryCommandState / execCommand system into a store (or some wrapper that also holds a store) that has state like isBold and canMakeBold and a makeBold() function.
    1. The consumer component will barely change from our last example. The only difference is the way we'll get a reference to our store (since now the store is exported from the JS module):
    2. In order to use this, we need to use a little more advanced readable store. Here's your example updated for this:
    3. // our temperature is now a store with initial value 0 const temperature = writable(0); // now we don't need to change this function, the change will be propaged // by the store itself const getTemperature = () => { return temperature; }
    4. Here's how we would rewrite our callback example with a store instead:
    1. For example, if we had a room of tall people wearing hats, and another room of Spanish speakers wearing hats, after combining those rooms, the only thing we know about every person is that they must be wearing a hat.
    1. Viewedthrough Fraser’s justice framework, more subtle powerimbalances come into view. The initiative was framedlargely by and through a scientific and technical lens.Participants were not provided with opportunities toreframe issues to fit their own needs and circumstancesbut were asked to work within existing frameworks setout by the United Nations Framework Convention onClimate Change. Opportunities for response were sig-nificantly circumscribed by closed, voting-style ques-tions.

      Critize of WWWViews through Fraser lens

    2. orld Wide Views (WWViews) is a timelyexperiment in forging global spaces for public dialoguethat simultaneously works within as well as transcendsnational borders (Blue, 2015). WWViews marks animportant innovation in scaling up formal publicengagement by connecting people from variousnation-states to discuss issues of global importancesuch as climate change.

      First example is of a multinational forum of organized participation and collective decision-making.



  19. Oct 2021
    1. const str = 'mañana mañana' const strReverse = str.split('').reverse().join('') // => "anãnam anañam" // notice how the first word has an ã rather ñ
    1. Another option is the use the functional library Ramda, while the syntax may be a bit different from the Ruby and Pure JS version, I find it to be more declarive: list = [null, "say", "kenglish", "co", null] R.reject(R.isNil, list) // return new array [ 'say', 'kenglish', 'co' ]
    1. const fetchWithJSONHeaders = applyDefaults(fetch, { headers: { "Content-Type": "application/json" } }); const fetchWithTextHeaders = applyDefaults(fetch, { headers: { "Content-Type": "application/text" } }); // Fetch JSON content const response = await fetchWithJSONHeaders("/users", { method: "GET" });
    1. For instance, the application could define a class method PaymentGateway.impl whose definition depends on the environment; or could define PaymentGateway to have a parent class or mixin that depends on the environment
  20. Sep 2021
    1. Democracy Collaborative contributes another framework

      Dëmocracy Collaborative framework - Measure and interpret impact on community - esp in area of low-income households. : Indicators: equity, econ dev, new biz, affordable housing, arts and culture, financial security of families, education of youth, better health and safety.

    2. action agenda’

      Action Agenda os Initiative for a Competitive Inner City - university as driver of economic prosperity for urban areas... with a socio-economic benfit (7 roles identified: Institution roles Economic roles Physical roles Public purpose Roles.

    3. The settlement house movement offers a prime example



    1. The neighborhood outside of the PAS is characterized by continued decline—median household incomes fell by 30% between 1990 and 2010 and its poverty rate exceeded the city’s, as well as the PAS area’s, by approximately 10% in 2010. The overall trends for University City, discussed previously, mask the observed socioeconomic divergence between the areas inside and outside of the catchment zone. In fact, it appears that the PAS area served as the bright spot in University City during the WPI years, while the remainder of the neighborhood experienced continued eco-nomic decline.Housing tre

      PAS catchment better. Outside in decline.

    2. wealth front, Philadelphia’s poverty rate steadily increased

      more poverty study black declined pop with influx of asia and small flight of whites. Home values doubled while occupancy increased.

      But inside the PAS catchment area, whites increase, blacks decreased and asians doubled. More rental, less vacancy... Less owner occupied. - signs of gentrification. Lower poverty.

    3. For example, the Ohio State University emphasized increased beautification and public safety initiatives, homeownership incen-tive programs, and mixed-use development projects to catalyze new private investment. The University of Cincinnati spurred revitalization by providing funds to and serving on the boards of five neighborhood community develop-ment corporations (CDCs), one for each of its adjacent neighborhoods. This strategy moves the institution into a partnership role with the neighborhood, rather than a leadership role. Several other books, articles, and reports empha-size other approaches universities are taking as urban property owners and real estate developers, economic engines, neighborhood partners, and civic leaders (e.g., Bunnell and Lawson 2006; Guinan, McKinley, and Yi 2013; Martin, Smith, and Phillips 2005; Maurrasse 2001; Mayfield and Lucas 2000; Perry, Wiewel, and Menendez 2009; Sungu-Eryilmaz 2009)

      Various case studies and their weaknesses.



    1. Under the rubric of business incentives, we include bothtax instruments—property tax abatements, tax incrementfinancing, sales tax exemptions and credits, and corporateincome tax exemptions and credits for investment or jobs—and non-tax incentives such as business grants, loans,and loan guarantees. In all cases, the firm, not the workeror work seeker, is the initial recipient of the incentive

      Examples of types of incentive included in their definition.



    1. y. In the Santa Barbara antigrowth movements, for example, much support is provided by professionals from research and electronics firms, as well as branch managers of small "high-technology" corporation

      Example of where anti-growth worked and evidence

    2. s the claim that growth "makes jo
    3. ocalities grow in population not simply as a function of migration but also because of the fecundity of the existing population. Some means are obvi- ously needed to provide jobs and housing to accommodate such growth- either in the immediate area or at some distant lo

      birth rates create growth. creating environmentla and budgetary stresses.

    4. s, growth benefits only a small proportion of local residents. Growth almost always brings with it the obvious problems of increased air and water pollution, traffic congestion, and overtaxing of natural a

      Growth has costs the affect many but benefit few.

    5. 49).4 In- creased utility and government costs caused by new development should be borne (and they usually are-see, e.g., Ann Arbor City Planning De- partment [1972]) by the public at large, rather than by those responsible for the "excess" demand on the urban infrast

      The public pays for these costs of extending land use.

    6. es; decisions made by private corporations also have major impac

      Private entities also seek to maximize use. And use gvt. as a tool to maximize use of land by reducing costs (through incentives).

    7. g way: an at- tempt is made to use government to gain those resources which will enhance the growth potential of the area unit in ques

      Gvts are interested in land use that enhances growth potential.



    1. leader of a community project, sponsored by a voluntary society, on a c

      Community-based research

    2. Dampness and mould growth were also a feature of some houses on the Whiteway and Twerton council

      dampness of homes in council estates in Bath. research for community advocacy. Collective action example.

    3. s. This study originated from the desire of tenants to obtain reliable data which they could use for their cause. They did not carry out the study but they were consulted so that its form would serve their needs. They subsequently made use of the findings to argue their case both to the media and to the local authori

      The study had benefit for the communities.

    4. Damp ho

      Damp rental homes creating health issues in Scotland.

    5. Brighton where the SSD had created o

      Brighton social services patch teams.

    1. config: path.resolve(__dirname, '../config'), vue: 'vue/dist/vue.js', src: path.resolve(__dirname, '../src'), store: path.resolve(__dirname, '../src/store'), assets: path.resolve(__dirname, '../src/assets'), components: path.resolve(__dirname, '../src/components'), '@': path.resolve(__dirname, '../src'),
    2. alias: { _self: path.join(__dirname, 'src/web'), _shared: path.join(__dirname, 'src/shared'), _components: path.join(__dirname, 'src/web/components'), _helpers: path.join(__dirname, 'src/web/helpers'), _layers: path.join(__dirname, 'src/web/layers'), _mutations: path.join(__dirname, 'src/web/mutations'), _routes: path.join(__dirname, 'src/web/routes') }
    3. alias: { '@components': path.join(srcDir, 'components'), '@modules': path.join(srcDir, 'modules'), '@store': path.join(srcDir, 'store') }
    4. alias: { '@shared': path.dirname(require.resolve('app')), '~': path.join(fs.realpathSync(process.cwd()), 'app'), },
    5. In this example, @shared is the package, ~ is the project. I wouldn't do it this way in the future, but I know this configuration works.
    1. alias: { Library: path.resolve(__dirname, "root/library/"), Single: path.resolve(__dirname, "root/test.js"), },
    2. alias: { Single$: path.resolve(__dirname, "root/test.js"), },
    1. Analytics modules that run in the background, monitor user interaction, and send the data to a server.
    2. Many jQuery plugins attach themselves to the global jQuery object.
    3. A polyfill for example, might not do anything, because it finds that the feature that it enables is already supported by the browser.
    1. Some would argue that the phrase ''survival of the fittest'' is tautological, in that the fittest are defined as those that survive to reproduce.
    1. One good use for /dev/tty is if you're trying to call an editor in a pipeline (e.g., with xargs). Since the standard input of xargs is some list of files rather than your terminal, just doing, e.g., | xargs emacs will screw up your terminal. Instead you can use | xargs sh -c 'emacs "$@" </dev/tty' emacs to connect the editor to your terminal even though the input of xargs is coming from elsewhere.
  21. Aug 2021
    1. Some details of my example were originally poorly chosen i.e. the example was constructed in a way that developer would probably have done a null check rather than a typeof comparison. I've addressed that now. My apologies to anyone who read this before-hand and thought the example seemed a bit too "fabricated".
    1. Using a flag to disable prettier for a line, the next line or until I activate it again (ESLint like syntax). // prettier-disable border: { sep: "║", topLeft: "╔", topMid: "╦", top: "═", topRight: "╗", midLeft: "╠", midMid: "╬", mid: "═", midRight: "╣", botLeft: "╚", botMid: "╩", bot: "═", botRight: "╝" }, // prettier-enable
    1. Here is one of the most confusing cases: def foo(x, **kwargs) p [x, kwargs] end def bar(x=1, **kwargs) p [x, kwargs] end foo({}) #=> [{}, {}] bar({}) #=> [1, {}] bar({}, **{}) #=> expected: [{}, {}], actual: [1, {}]
    2. If you extend a method to accept keyword arguments, the method may have incompatibility as follows: # If a method accepts rest argument and no `**nil` def foo(*args) p args end # Passing keywords are converted to a Hash object (even in Ruby 3.0) foo(k: 1) #=> [{:k=>1}] # If the method is extended to accept a keyword def foo(*args, mode: false) p args end # The existing call may break foo(k: 1) #=> ArgumentError: unknown keyword k
    1. Ronald Reagan also kept a similar system that apparently very few people knew about until he died. In his system, he used 3×5 notecards and kept them in a photo binder by theme. These note cards–which were mostly filled with quotes–have actually been turned into a book edited by the historian Douglas Brinkley. These were not only responsible for many of his speeches as president, but before office Reagan delivered hundreds of talks as part of his role at General Electric. There are about 50 years of practical wisdom in these cards. Far more than anything I’ve assembled–whatever you think of the guy. I highly recommend at least looking at it.

      Ronald Reagan kept a commonplace in the form of index cards which he kept in a photo binder and categorized according to theme. Douglas Brinkley edited them into the book The Notes: Ronald Reagan's Private Collection of Stories and Wisdom.

  22. Jun 2021