Commit 9f6dc24
Improve doctor async checks: enhance regex precision and add comprehensive tests
- Remove overly broad string form regex that could cause false positives
- Add support for both :async symbol and async: true hash syntax
- Add word boundary \b to prevent matching :async_mode or similar
- Improve multi-line javascript_pack_tag detection
- Add comprehensive inline documentation with examples
- Add test for async: true pattern detection
- Add test to confirm defer: "async" does not trigger false positive
- Add test for multi-line javascript_pack_tag calls
- Improve comment filtering logic to handle multi-line tags correctly
- Use String#include? for better performance (RuboCop compliance)
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>1 parent 8382e94 commit 9f6dc24
File tree
2 files changed
+91
-11
lines changed- lib/react_on_rails
- spec/lib/react_on_rails
2 files changed
+91
-11
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1203 | 1203 | | |
1204 | 1204 | | |
1205 | 1205 | | |
1206 | | - | |
| 1206 | + | |
| 1207 | + | |
| 1208 | + | |
| 1209 | + | |
| 1210 | + | |
| 1211 | + | |
| 1212 | + | |
| 1213 | + | |
| 1214 | + | |
| 1215 | + | |
| 1216 | + | |
| 1217 | + | |
| 1218 | + | |
1207 | 1219 | | |
1208 | 1220 | | |
1209 | 1221 | | |
1210 | 1222 | | |
| 1223 | + | |
| 1224 | + | |
| 1225 | + | |
| 1226 | + | |
| 1227 | + | |
| 1228 | + | |
| 1229 | + | |
| 1230 | + | |
1211 | 1231 | | |
1212 | | - | |
1213 | | - | |
1214 | | - | |
1215 | | - | |
1216 | | - | |
1217 | | - | |
| 1232 | + | |
| 1233 | + | |
1218 | 1234 | | |
1219 | | - | |
1220 | | - | |
| 1235 | + | |
| 1236 | + | |
| 1237 | + | |
| 1238 | + | |
| 1239 | + | |
| 1240 | + | |
| 1241 | + | |
| 1242 | + | |
| 1243 | + | |
1221 | 1244 | | |
1222 | 1245 | | |
1223 | 1246 | | |
| |||
1229 | 1252 | | |
1230 | 1253 | | |
1231 | 1254 | | |
1232 | | - | |
| 1255 | + | |
1233 | 1256 | | |
1234 | | - | |
| 1257 | + | |
| 1258 | + | |
| 1259 | + | |
| 1260 | + | |
| 1261 | + | |
| 1262 | + | |
1235 | 1263 | | |
1236 | 1264 | | |
1237 | 1265 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
292 | 292 | | |
293 | 293 | | |
294 | 294 | | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
295 | 329 | | |
296 | 330 | | |
297 | 331 | | |
| |||
355 | 389 | | |
356 | 390 | | |
357 | 391 | | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
| 396 | + | |
| 397 | + | |
| 398 | + | |
| 399 | + | |
| 400 | + | |
| 401 | + | |
| 402 | + | |
| 403 | + | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
358 | 410 | | |
359 | 411 | | |
360 | 412 | | |
| |||
0 commit comments