You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: website/i18n/en/docusaurus-plugin-content-docs/current/guides/examples/auth.mdx
+49-14
Original file line number
Diff line number
Diff line change
@@ -7,6 +7,9 @@ import WIP from '@site/src/shared/ui/wip/tmpl.mdx'
7
7
8
8
# Auth
9
9
10
+
importTabsfrom'@theme/Tabs';
11
+
importTabItemfrom'@theme/TabItem';
12
+
10
13
Every application has business logic related **with the current authorized user.**
11
14
12
15
> Usually such an entity is called `Viewer` / `Principle` / `Session` - but within the framework of the article, we will focus on `viewer`, but it all depends on your project and team
@@ -21,9 +24,10 @@ Let's look at them in more detail below with examples
21
24
22
25
*The methodology does not regulate this level of nesting in any way yet*
23
26
24
-
2. It should also be understood that the examples given below are abstract and synthetic, and are formed by the author's point of view and experience
27
+
2. It should also be understood that the examples below are abstract and synthetic, and are formed to demonstrate only the concepts of the methodology
28
+
29
+
*FeatureSliced does not regulate the best practices of a particular data-fetcher or state-manager*
25
30
26
-
*The implementation in your projects may differ, the methodology, again, does not regulate these aspects in any way*
27
31
28
32
:::
29
33
@@ -73,12 +77,33 @@ export { ViewerAvatar } from "./avatar";
73
77
...
74
78
```
75
79
80
+
<Tabs>
81
+
<TabItemvalue="redux"label="Redux"default>
82
+
83
+
In redux, the [redux-ducks](https://github.com/erikra/ducks-modular-redux) approach is generally accepted when its units (selectors/actions/...) they lie side by side and are clearly decomposed
84
+
85
+
But explicit decomposition is not required
86
+
76
87
```ts title=entities/user/model/index.ts
77
88
export*asselectorsfrom"./selectors";
78
89
export*aseventsfrom"./events";
79
90
export*asstoresfrom"./stores";
80
91
...
81
92
```
93
+
</TabItem>
94
+
<TabItemvalue="effector"label="Effector">
95
+
96
+
The effector model will most often consist of a single file - because it is customary to store all units side by side there
97
+
98
+
If the units in the model can be schematically divided into several submodels, then [you can explicitly do this](https://github.com/feature-sliced/examples/pull/1#discussion_r654841332) denote in the Public API
0 commit comments