Do line break and word break in Yii2 GridView

have a look at "options" and  "contentOptions" in code

    <?= GridView::widget([
        'dataProvider' => $dataProvider,
        'filterModel' => $searchModel,
        'options' => [
                'style'=>'overflow: auto; word-wrap: break-word;'
        ],
        'columns' => [
            ['class' => 'yii\grid\SerialColumn'],

....

            [
                'attribute'=>'pi_desc',
                'value'=>function ($model) { return $model->pi_desc; },
                'format'=>'raw',
                'label'=>'Desc',
                'contentOptions' => ['style'=>'max-width:300px;'],
            ],