diff --git a/.github/workflows/discord_notify.yml b/.github/workflows/discord_notify.yml index ff2caa1bf..3132a0228 100644 --- a/.github/workflows/discord_notify.yml +++ b/.github/workflows/discord_notify.yml @@ -2,7 +2,11 @@ name: Discord Notify on: pull_request_target: +<<<<<<< HEAD types: [ labeled ] +======= + types: [opened, ready_for_review] +>>>>>>> ab18d2f0f5151ab0c927a12eb0a64f8170762eff jobs: notify: diff --git a/src/content/blog/index.md b/src/content/blog/index.md index ae3c26034..d1c022fa7 100644 --- a/src/content/blog/index.md +++ b/src/content/blog/index.md @@ -7,7 +7,7 @@ title: React Blog This blog is the official source for the updates from the React team. Anything important, including release notes or deprecation notices, will be posted here first. -You can also follow the [@react.dev](https://bsky.app/profiles/react.js) account on Bluesky, or [@reactjs](https://twitter.com/reactjs) account on Twitter, but you won’t miss anything essential if you only read this blog. +You can also follow the [@react.dev](https://bsky.app/profile/react.dev) account on Bluesky, or [@reactjs](https://twitter.com/reactjs) account on Twitter, but you won’t miss anything essential if you only read this blog. diff --git a/src/content/learn/creating-a-react-app.md b/src/content/learn/creating-a-react-app.md index f645745d0..aa43b1a1f 100644 --- a/src/content/learn/creating-a-react-app.md +++ b/src/content/learn/creating-a-react-app.md @@ -111,11 +111,11 @@ Server Components and Suspense are React features rather than Next.js features. If your app has constraints not well-served by existing frameworks, you prefer to build your own framework, or you just want to learn the basics of a React app, there are other options available for starting a React project from scratch. -Starting from scratch gives you more flexibility, but does require that you make choices on which tools to use for routing, data fetching, and other common usage patterns. It's a lot like building your own framework, instead of using a framework that already exists. The [frameworks we recommend](#recommended-react-frameworks) have built-in solutions for these problems. +Starting from scratch gives you more flexibility, but does require that you make choices on which tools to use for routing, data fetching, and other common usage patterns. It's a lot like building your own framework, instead of using a framework that already exists. The [frameworks we recommend](#full-stack-frameworks) have built-in solutions for these problems. If you want to build your own solutions, see our guide to [build a React app from Scratch](/learn/build-a-react-app-from-scratch) for instructions on how to set up a new React project starting with a built tool like [Vite](https://vite.dev/), [Parcel](https://parceljs.org/), or [RSbuild](https://rsbuild.dev/). ----- -_If you’re a framework author interested in being included on this page, [please let us know](https://github.com/reactjs/react.dev/issues/new?assignees=&labels=type%3A+framework&projects=&template=3-framework.yml&title=%5BFramework%5D%3A+)._ \ No newline at end of file +_If you’re a framework author interested in being included on this page, [please let us know](https://github.com/reactjs/react.dev/issues/new?assignees=&labels=type%3A+framework&projects=&template=3-framework.yml&title=%5BFramework%5D%3A+)._ diff --git a/src/content/learn/passing-data-deeply-with-context.md b/src/content/learn/passing-data-deeply-with-context.md index 86f089a24..799921bcb 100644 --- a/src/content/learn/passing-data-deeply-with-context.md +++ b/src/content/learn/passing-data-deeply-with-context.md @@ -468,15 +468,19 @@ import { LevelContext } from './LevelContext.js'; export default function Section({ level, children }) { return (
- + {children} - +
); } ``` +<<<<<<< HEAD Bu React'a şunu söyler: "`
` içindeki herhangi bir eleman,`LevelContext`'i istediğinde, ona bu `level` değerini ver." Bileşen, üzerindeki UI ağacında bulunan en yakın `` değerini kullanır. +======= +This tells React: "if any component inside this `
` asks for `LevelContext`, give them this `level`." The component will use the value of the nearest `` in the UI tree above it. +>>>>>>> ab18d2f0f5151ab0c927a12eb0a64f8170762eff @@ -514,9 +518,9 @@ import { LevelContext } from './LevelContext.js'; export default function Section({ level, children }) { return (
- + {children} - +
); } @@ -566,9 +570,15 @@ export const LevelContext = createContext(1); Orijinal kodla aynı sonucu elde edersiniz, ancak her `Heading` bileşenine `level` prop'unu aktarmanız gerekmez! Bunun yerine, üstündeki en yakın `Section` bileşenine sorarak başlık seviyesini "bulur": +<<<<<<< HEAD 1. `level` prop'unu `
`'a aktarırsınız. 2. `Section` alt bileşenlerini `` sarmalar. 3. `Heading`, `useContext(LevelContext)` ile birlikte yukarıdaki en yakın `LevelContext`'e değerini sorar. +======= +1. You pass a `level` prop to the `
`. +2. `Section` wraps its children into ``. +3. `Heading` asks the closest value of `LevelContext` above with `useContext(LevelContext)`. +>>>>>>> ab18d2f0f5151ab0c927a12eb0a64f8170762eff ## Context değerini provider'ının tanımlandığı bileşende okuma {/*using-and-providing-context-from-the-same-component*/} @@ -595,9 +605,9 @@ export default function Section({ children }) { const level = useContext(LevelContext); return (
- + {children} - +
); } @@ -643,9 +653,9 @@ export default function Section({ children }) { const level = useContext(LevelContext); return (
- + {children} - +
); } @@ -777,9 +787,9 @@ export default function Section({ children, isFancy }) { 'section ' + (isFancy ? 'fancy' : '') }> - + {children} - +
); } @@ -868,6 +878,7 @@ Genellikle, bazı bilgilere ağacın farklı bölümlerindeki bileşenler taraf +<<<<<<< HEAD * Context, bir elemanın altındaki tüm ağaca bilgi aktarmasını sağlar. * Context'i aktarmak için: 1. `export const MyContext = createContext(defaultValue)` ile oluşturun ve dışa aktarın. @@ -876,6 +887,16 @@ Genellikle, bazı bilgilere ağacın farklı bölümlerindeki bileşenler taraf * Context ortada bulunan herhangi bir elamandan aktarılır. * Context, "çevresine adapte olan" bileşenler yazmanıza olanak sağlar. * Context kullanmadan önce, prop olarak aktarmayı veya JSX'i `children` olarak iletmeyi deneyin. +======= +* Context lets a component provide some information to the entire tree below it. +* To pass context: + 1. Create and export it with `export const MyContext = createContext(defaultValue)`. + 2. Pass it to the `useContext(MyContext)` Hook to read it in any child component, no matter how deep. + 3. Wrap children into `` to provide it from a parent. +* Context passes through any components in the middle. +* Context lets you write components that "adapt to their surroundings". +* Before you use context, try passing props or passing JSX as `children`. +>>>>>>> ab18d2f0f5151ab0c927a12eb0a64f8170762eff @@ -1026,7 +1047,11 @@ li { `imageSize` prop'unu bütün bileşenlerden kaldırın. +<<<<<<< HEAD `Context.js` dosyasında `ImageSizeContext`'i oluşturun ve dışa aktarın. Ardından değeri aşağı aktarmak için `List`'i `` ile sarın ve `useContext(ImageSizeContext)` kullanarak `PlaceImage` bileşeninde değerini okuyun: +======= +Create and export `ImageSizeContext` from `Context.js`. Then wrap the List into `` to pass the value down, and `useContext(ImageSizeContext)` to read it in the `PlaceImage`: +>>>>>>> ab18d2f0f5151ab0c927a12eb0a64f8170762eff @@ -1040,7 +1065,7 @@ export default function App() { const [isLarge, setIsLarge] = useState(false); const imageSize = isLarge ? 150 : 100; return ( -
-
+
) }