Sobes.tech

How does a simple Union differ from a discriminated union?

268

The form that the user hasn't even started editing has already produced a validation error. Is this the correct behavior or not?

233

What is currently the 'ceiling' for you in your current job, which made you decide to look for a new place?

190

Do you know what happens if you write return and leave it empty (without a value)?

177

type Row = { id: number; name: string; } const tableData: Row[] = [ {id: 1, name: "A"}, {id: 2, name: "B"} ] type Validator = (value: unknown) => string | undefined; console.log("...");

171

type Row = { id: number; name: string; } const tableData: Row[] = [ {id: 1, name: "A"}, {id: 2, name: "B"}, ] type Validator = (value: unknown) => string | undefined; console.log("...");

170

Can you explain what happens in the system when a user clicks to edit the first row of the table?

168

If the user edits string A, and its current value of polyname matches the original value, the validator should not produce an error. Why does your implementation of the validator produce an error in this case, given that the initial value of the field matches itself?

166

What did you do before transitioning into development?

143

Why did you decide to switch to a new stack/change activity? What was the reason if you worked in a company for 10 years?

139

Did you have any experience before development, what did you do?

138

When the form opens for editing the first row, the polyname field is filled with the value from that row (for example, 'A'). The validator you wrote is triggered. Do you think it is normal behavior for the validator to find a match and produce an error even though the user has not yet started editing?

136

Tell us what your development team is currently working on and what you are doing.

133

Regarding the last 4-5 years of work, which task do you remember most and why?

131

How to modify the validator to perform case-insensitive uniqueness check, considering that the component props have access to the entire data table and the row id being edited?

127

What will the validator you wrote output if the user clicked to edit the first row and the value of name/polyname is equal to the original value of that row?

127

A requirement has appeared: the polyname field should not match other names (polyname) in the table. How to implement such a uniqueness check?

126

What attracted you to your company? What would you like to find at your new job?

123

At the moment of the first form render, when the field is already filled with an initial string value (e.g., 'A'), and the validator is called with a value equal to 'A', which corresponds to a specific string in your code — should there be an error in this case or not?

118

Write a validator using the given function signature (line 11 in the editor). Note that value has type unknown, as the form does not know the exact type of the field, but it is assumed to be a string. Please use arrow functions instead of the function keyword.

115
/2