اشتراک‌ها
پاسخ به برترین سوالات Python
Wondering how the pros solve that Python question? Find out with Content Developer Eric Camplin, as he hosts a team of Python Developers, including popular expert Steve Dower, who answer top Python questions for all skill levels and dive into best practices for this versatile and easy-to-use programming language.

Get practical tips, learn EAFP (“It’s Easier to Ask Forgiveness than Permission”) in working with files in Python, call external commands, look at “lazy lists,” use True/False properties of Python lists to check whether one is empty, and lots more. Plus, over time, watch this space for additional question and answer sets, as you explore the top questions programmers have about Python. 
پاسخ به برترین سوالات Python
اشتراک‌ها
WPF و IOC در NET Core 3.0.

At work, we are planning to migrate our WPF application from .NET Framework 4.7 to .NET Core 3.0. The main reason for doing so is that it was always a big pain to organize the updates of the .NET Framework on our customer machines. So being able to bundle .NET Core with our application is a big plus for us. Then, for sure, we are looking for the performance improvements brought by .NET Core and finally the new capabilities brought by the fast pace of innovation of .NET Core. 

WPF و IOC در NET Core 3.0.
اشتراک‌ها
ReSharper Ultimate 2016.1.1 منتشر شد

ReSharper 2016.1.1. The update helps ReSharper see controllers outside of ASP.NET MVC areas and folders again (RSRP-458398, RSRP-455213); adds smart, license-aware update checks; enables bulk renaming in TypeScript (RSRP-458570); fixes Go to Everything so that it works after suspending and resuming ReSharper (RSRP-458404); improves performance in solutions with large JavaScript and JSON files (RSRP-458363); fixes pessimistic mode in value analysis (RSRP-458210); makes IL Viewer available via the Navigate To pop-up (RSRP-458323); improves details of ReactJS support (RSRP-458229, RSRP-458242, RSRP-458308). See all fixes in ReSharper 2016.1.1.  

ReSharper Ultimate 2016.1.1 منتشر شد
اشتراک‌ها
یک گرید ساده با قابلیت راست به چپ و پیجینگ در ری اکت
در این مقاله قصد دارم شمارو را با امکانات لایبرری "ری اکت انگرید " برای ری اکت جی اس آشنا کنم. این لایبرری شامل یک کامپوننت گرید با قابلیت‌های زیر هست:

1-ساپورت راست به چپ
2- نمایش پیجینگ
3-  نمایش لودر
4- امکان تغییر کلمات
5- امکان جاگذاری کامپوننت در هر سل

نحوه استفاده از این کامپوننت به این شکل هست:

1- تعریف ستونها:
const columns = [
    {
      field: "fullname",
      headerName: "First & last Name",
      description: "name of user",
      width: 50,
    },
    {
      field: "age",
      headerName: "Age",
      description: "age of user",
      width: 50,
      renderCell:(info)=><strong>Age is : {info.data.age}</strong>
    }
]

2- تعریف استیت‌های لازم برا ست کردن سطر ها، لودر، تعداد کل, شماره صفحه و بزرگی هر صفحه(دقت شود که امکان استفاده بدون پیجینگ هم وجود دارد و امکانات کامل را در لینک لایبرری میتوانید مطالعه نمایید) 
...
const [rows,setRows] = useState([]);
const [loading,setLoading] = useState(false);
const [totalCount,setTotalCount] = useState(0);
const [filter,setFilter] = useState({ pageSize:10, pageNumber:1 });
const _fetchData = async () => { if (!active) return; //mock api, you can call your api then set data to table like commented line below return new Promise((resolve) => { setLoading(true); setTimeout(() => { setRows(data);// SetRows, note that data comes from api and must be array of objects setTotalCount(7);//=== set total page size for pagination part resolve(); setLoading(false); }, 2000); }); }
3- در نهایت کامپوننت مورد نظر:
import Angrid from "rect-angrid";
...
_handlePageChange = (newPage)=>{
    setFilter(p=>({...p,pageNumber:newPage}))
}
...
      <AnGrid
        loading={loading}
        columns={columns}
        rows={rows}
        showRowNumber={true}
        pageSize={filter.pageSize}
        pageNumber={filter.pageNumber}
        totalCount={totalCount}
        onPageChange={_handlePageChange}
        theme="dark"
        minHeight={300}
        emptyList={<strong>There Is No Info</strong>}
      />
نمایی از گرید:



یک گرید ساده با قابلیت راست به چپ و پیجینگ در ری اکت