JSFiddle - React, Tailwind, and code Playground

HTML

<button>button</button>

JavaScript

$.ajaxSetup({
    flatOptions: {
        priv2: true
    }
});

$('button').click(function() {
    var v1 = {  };
    var v2 = { y: v1 };
    v1.x = v2;

    $.ajax({
        url: 'someurl/',
        beforeSend: function() {
            this.priv1 = v1;
        },
        priv2: v2,
        cache: false
    }).done(function() {
        console.log( "priv1", this.priv1 );
        console.log( "priv2", this.priv2 );
    });
});