I use the following:
autocmd FilterWritePre * if &diff | setlocal wrap< | endif
FilterWritePre
is triggered immediately before a generated diff is written to the buffer, and setlocal wrap<
copies the global value of wrap
. Of course it’s also possible to simply force setlocal wrap
.